# Re: \[PATCH 2/9\] timers: provide a "modern" variant of timers

- From: Arnd Bergmann \<arnd@arndb.de\>
- Date: 2017-05-18 08:58:02 
- List: linuxppc-dev
- Page: https://ratatoskr.run/linuxppc-dev/2017/05/4998624
- Thread: https://ratatoskr.run/linuxppc-dev/2017/05/4997071/t.md

```text
On Thu, May 18, 2017 at 10:41 AM, Christoph Hellwig [ref] wrote:
> On Thu, May 18, 2017 at 10:24:48AM +0200, Christoph Hellwig wrote:
>> > b) give the union a name (breaks any reference to timer_list->func in C code):
>> >
>> >  +       union {
>> >  +               void            (*func)(struct timer_list *timer);
>> >  +               void            (*function)(unsigned long);
>> >  +       } u;
>>
>> I'll look into that, as it seems a lot safer, and places outside
>> the timer code shouldn't really touch it (although I bet they do,
>> so more fixes for this series..)
>
> Meh.  All the old init_timer users set function directly, so
> I guess we need to use the other approach.

How expensive would it be to add another field to timer_list and
just have both pointers?

      Arnd
```
