diff options
author | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-02-13 16:10:08 -0800 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-02-13 16:10:08 -0800 |
commit | 58a3bb59973e33a428d72fa530a3d1d81feb0e8f (patch) | |
tree | 11a6f4838ec20d96bc287a62f21c4b10f0c86b1a /drivers/char/watchdog/sc520_wdt.c | |
parent | 7f1f86a0d04e79f8165e6f50d329a520b8cd11e5 (diff) | |
parent | 88d5a7bb75b5e8f600e79b16abaf008c7fdfd27d (diff) |
Merge master.kernel.org:/pub/scm/linux/kernel/git/wim/linux-2.6-watchdog
* master.kernel.org:/pub/scm/linux/kernel/git/wim/linux-2.6-watchdog: (23 commits)
[WATCHDOG] timers cleanup
[WATCHDOG] ib700wdt.c - convert to platform_device part 2
[WATCHDOG] ib700wdt.c - convert to platform_device
[WATCHDOG] ib700wdt.c spinlock/WDIOC_SETOPTIONS changes
[WATCHDOG] ib700wdt.c small clean-up's
[WATCHDOG] ib700wdt.c clean-up init and exit routines
[WATCHDOG] ib700_wdt.c stop + set_heartbeat operations
[WATCHDOG] show default value for nowayout in module parameter
[WATCHDOG] advantechwdt.c - convert to platform_device part 2
[WATCHDOG] advantechwdt.c - convert to platform_device
[WATCHDOG] advantechwdt.c - move set_heartbeat to a seperate function
[WATCHDOG] advantechwdt.c - cleanup before platform_device patches
[WATCHDOG] acquirewdt.c - convert to platform_device part 2
[WATCHDOG] acquirewdt.c - convert to platform_device
[WATCHDOG] acquirewdt.c - clean before platform_device patches
[WATCHDOG] pcwd_usb.c - get heartbeat from dip switches
[WATCHDOG] pcwd.c - e-mail adres update
[WATCHDOG] pcwd_usb.c - get heartbeat from dip switches
[WATCHDOG] pcwd_usb.c - document includes
[WATCHDOG] pcwd_pci.c - spinlock fixes
...
Diffstat (limited to 'drivers/char/watchdog/sc520_wdt.c')
-rw-r--r-- | drivers/char/watchdog/sc520_wdt.c | 14 |
1 files changed, 4 insertions, 10 deletions
diff --git a/drivers/char/watchdog/sc520_wdt.c b/drivers/char/watchdog/sc520_wdt.c index caec37ba750..2676a43895a 100644 --- a/drivers/char/watchdog/sc520_wdt.c +++ b/drivers/char/watchdog/sc520_wdt.c @@ -97,7 +97,7 @@ MODULE_PARM_DESC(timeout, "Watchdog timeout in seconds. (1<=timeout<=3600, defau static int nowayout = WATCHDOG_NOWAYOUT; module_param(nowayout, int, 0); -MODULE_PARM_DESC(nowayout, "Watchdog cannot be stopped once started (default=CONFIG_WATCHDOG_NOWAYOUT)"); +MODULE_PARM_DESC(nowayout, "Watchdog cannot be stopped once started (default=" __MODULE_STRING(WATCHDOG_NOWAYOUT) ")"); /* * AMD Elan SC520 - Watchdog Timer Registers @@ -121,7 +121,7 @@ MODULE_PARM_DESC(nowayout, "Watchdog cannot be stopped once started (default=CON static __u16 __iomem *wdtmrctl; static void wdt_timer_ping(unsigned long); -static struct timer_list timer; +static DEFINE_TIMER(timer, wdt_timer_ping, 0, 0); static unsigned long next_heartbeat; static unsigned long wdt_is_open; static char wdt_expect_close; @@ -145,8 +145,7 @@ static void wdt_timer_ping(unsigned long data) spin_unlock(&wdt_spinlock); /* Re-set the timer interval */ - timer.expires = jiffies + WDT_INTERVAL; - add_timer(&timer); + mod_timer(&timer, jiffies + WDT_INTERVAL); } else { printk(KERN_WARNING PFX "Heartbeat lost! Will not ping the watchdog\n"); } @@ -179,8 +178,7 @@ static int wdt_startup(void) next_heartbeat = jiffies + (timeout * HZ); /* Start the timer */ - timer.expires = jiffies + WDT_INTERVAL; - add_timer(&timer); + mod_timer(&timer, jiffies + WDT_INTERVAL); /* Start the watchdog */ wdt_config(WDT_ENB | WDT_WRST_ENB | WDT_EXP_SEL_04); @@ -389,10 +387,6 @@ static int __init sc520_wdt_init(void) spin_lock_init(&wdt_spinlock); - init_timer(&timer); - timer.function = wdt_timer_ping; - timer.data = 0; - /* Check that the timeout value is within it's range ; if not reset to the default */ if (wdt_set_heartbeat(timeout)) { wdt_set_heartbeat(WATCHDOG_TIMEOUT); |