RE: [PATCH 2/9] timers: provide a "modern" variant of timers

From
David Laight <hidden>
Date
2017-05-19 10:49:04
Also in
linux-s390, lkml
Reply to
Christoph Hellwig, 2017-05-16
From: Christoph Hellwig
Sent: 16 May 2017 12:48

The new callback gets a pointer to the timer_list itself, which can
then be used to get the containing structure using container_of
instead of casting from and to unsigned long all the time.
What about sensible drivers that put some other value in the 'data'
field?

Perhaps it ought to have been 'void *data'.

Seems retrograde to be passing the address of the timer structure
(which, in principle, the callers no nothing about).

So I wouldn't call it 'modern', just different.

	David
Thread (39 messages) 39 messages, 7 authors, last reply 2017-05-23
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help