diff options
| author | Hans Petter Selasky <hselasky@FreeBSD.org> | 2018-03-13 17:04:14 +0000 |
|---|---|---|
| committer | Hans Petter Selasky <hselasky@FreeBSD.org> | 2018-03-13 17:04:14 +0000 |
| commit | 30174d9d512a5546ead175a229433c0b3b366ad8 (patch) | |
| tree | a97f3583b1e3967e11d1aad316bd77dda0219d75 /sys/compat | |
| parent | 80b6262861b8b9657c75002d038844cd72dbda46 (diff) | |
Notes
Diffstat (limited to 'sys/compat')
| -rw-r--r-- | sys/compat/linuxkpi/common/include/linux/timer.h | 12 | ||||
| -rw-r--r-- | sys/compat/linuxkpi/common/src/linux_compat.c | 6 |
2 files changed, 9 insertions, 9 deletions
diff --git a/sys/compat/linuxkpi/common/include/linux/timer.h b/sys/compat/linuxkpi/common/include/linux/timer.h index d046b6e141a5..b4881b0b33ac 100644 --- a/sys/compat/linuxkpi/common/include/linux/timer.h +++ b/sys/compat/linuxkpi/common/include/linux/timer.h @@ -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) diff --git a/sys/compat/linuxkpi/common/src/linux_compat.c b/sys/compat/linuxkpi/common/src/linux_compat.c index ed0cf514e3f4..a29702d11723 100644 --- a/sys/compat/linuxkpi/common/src/linux_compat.c +++ b/sys/compat/linuxkpi/common/src/linux_compat.c @@ -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); } |
