Commit 9555cfd2 authored by Hans Petter Selasky's avatar Hans Petter Selasky
Browse files

Rename callout member in struct timer_list to match the one in struct

delayed_work in the LinuxKPI. This allows the timer_pending() function
macro to be used with delayed work structures.

No functional nor structural change.

MFC after:	1 week
Submitted by:	Johannes Lundberg <johalun0@gmail.com>
Sponsored by:	Mellanox Technologies
Sponsored by:	Limelight Networks
parent 90575a0e
......@@ -38,7 +38,7 @@
#include <sys/callout.h>
struct timer_list {
struct callout timer_callout;
struct callout callout;
void (*function) (unsigned long);
unsigned long data;
int expires;
......@@ -51,7 +51,7 @@ extern unsigned long linux_timer_hz_mask;
#define setup_timer(timer, func, dat) do { \
(timer)->function = (func); \
(timer)->data = (dat); \
callout_init(&(timer)->timer_callout, 1); \
callout_init(&(timer)->callout, 1); \
} while (0)
#define __setup_timer(timer, func, dat, flags) do { \
......@@ -62,16 +62,16 @@ extern unsigned long linux_timer_hz_mask;
#define init_timer(timer) do { \
(timer)->function = NULL; \
(timer)->data = 0; \
callout_init(&(timer)->timer_callout, 1); \
callout_init(&(timer)->callout, 1); \
} while (0)
extern void mod_timer(struct timer_list *, int);
extern void add_timer(struct timer_list *);
extern void add_timer_on(struct timer_list *, int cpu);
#define del_timer(timer) (void)callout_stop(&(timer)->timer_callout)
#define del_timer_sync(timer) (void)callout_drain(&(timer)->timer_callout)
#define timer_pending(timer) callout_pending(&(timer)->timer_callout)
#define del_timer(timer) (void)callout_stop(&(timer)->callout)
#define del_timer_sync(timer) (void)callout_drain(&(timer)->callout)
#define timer_pending(timer) callout_pending(&(timer)->callout)
#define round_jiffies(j) \
((int)(((j) + linux_timer_hz_mask) & ~linux_timer_hz_mask))
#define round_jiffies_relative(j) round_jiffies(j)
......
......@@ -1734,7 +1734,7 @@ mod_timer(struct timer_list *timer, int expires)
{
timer->expires = expires;
callout_reset(&timer->timer_callout,
callout_reset(&timer->callout,
linux_timer_jiffies_until(expires),
&linux_timer_callback_wrapper, timer);
}
......@@ -1743,7 +1743,7 @@ void
add_timer(struct timer_list *timer)
{
callout_reset(&timer->timer_callout,
callout_reset(&timer->callout,
linux_timer_jiffies_until(timer->expires),
&linux_timer_callback_wrapper, timer);
}
......@@ -1752,7 +1752,7 @@ void
add_timer_on(struct timer_list *timer, int cpu)
{
callout_reset_on(&timer->timer_callout,
callout_reset_on(&timer->callout,
linux_timer_jiffies_until(timer->expires),
&linux_timer_callback_wrapper, timer, cpu);
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment