aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/watchdog
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/watchdog')
-rw-r--r--drivers/watchdog/alim1535_wdt.c4
-rw-r--r--drivers/watchdog/davinci_wdt.c4
-rw-r--r--drivers/watchdog/i6300esb.c4
-rw-r--r--drivers/watchdog/ib700wdt.c4
-rw-r--r--drivers/watchdog/machzwd.c7
-rw-r--r--drivers/watchdog/mpc83xx_wdt.c5
-rw-r--r--drivers/watchdog/pc87413_wdt.c4
-rw-r--r--drivers/watchdog/pnx4008_wdt.c4
-rw-r--r--drivers/watchdog/sbc8360.c3
-rw-r--r--drivers/watchdog/sc1200wdt.c3
-rw-r--r--drivers/watchdog/sc520_wdt.c4
-rw-r--r--drivers/watchdog/smsc37b787_wdt.c4
-rw-r--r--drivers/watchdog/w83627hf_wdt.c4
-rw-r--r--drivers/watchdog/w83697hf_wdt.c4
-rw-r--r--drivers/watchdog/w83877f_wdt.c4
-rw-r--r--drivers/watchdog/w83977f_wdt.c4
-rw-r--r--drivers/watchdog/wafer5823wdt.c4
-rw-r--r--drivers/watchdog/wdt977.c4
-rw-r--r--drivers/watchdog/wdt_pci.c3
19 files changed, 20 insertions, 57 deletions
diff --git a/drivers/watchdog/alim1535_wdt.c b/drivers/watchdog/alim1535_wdt.c
index c404fc69e7e6..b481cc0e32e4 100644
--- a/drivers/watchdog/alim1535_wdt.c
+++ b/drivers/watchdog/alim1535_wdt.c
@@ -31,7 +31,7 @@ static unsigned long ali_is_open;
31static char ali_expect_release; 31static char ali_expect_release;
32static struct pci_dev *ali_pci; 32static struct pci_dev *ali_pci;
33static u32 ali_timeout_bits; /* stores the computed timeout */ 33static u32 ali_timeout_bits; /* stores the computed timeout */
34static spinlock_t ali_lock; /* Guards the hardware */ 34static DEFINE_SPINLOCK(ali_lock); /* Guards the hardware */
35 35
36/* module parameters */ 36/* module parameters */
37static int timeout = WATCHDOG_TIMEOUT; 37static int timeout = WATCHDOG_TIMEOUT;
@@ -398,8 +398,6 @@ static int __init watchdog_init(void)
398{ 398{
399 int ret; 399 int ret;
400 400
401 spin_lock_init(&ali_lock);
402
403 /* Check whether or not the hardware watchdog is there */ 401 /* Check whether or not the hardware watchdog is there */
404 if (ali_find_watchdog() != 0) { 402 if (ali_find_watchdog() != 0) {
405 return -ENODEV; 403 return -ENODEV;
diff --git a/drivers/watchdog/davinci_wdt.c b/drivers/watchdog/davinci_wdt.c
index e49a36c0d4d6..a61cbd48dc07 100644
--- a/drivers/watchdog/davinci_wdt.c
+++ b/drivers/watchdog/davinci_wdt.c
@@ -61,7 +61,7 @@
61 61
62static int heartbeat = DEFAULT_HEARTBEAT; 62static int heartbeat = DEFAULT_HEARTBEAT;
63 63
64static spinlock_t io_lock; 64static DEFINE_SPINLOCK(io_lock);
65static unsigned long wdt_status; 65static unsigned long wdt_status;
66#define WDT_IN_USE 0 66#define WDT_IN_USE 0
67#define WDT_OK_TO_CLOSE 1 67#define WDT_OK_TO_CLOSE 1
@@ -200,8 +200,6 @@ static int davinci_wdt_probe(struct platform_device *pdev)
200 int ret = 0, size; 200 int ret = 0, size;
201 struct resource *res; 201 struct resource *res;
202 202
203 spin_lock_init(&io_lock);
204
205 if (heartbeat < 1 || heartbeat > MAX_HEARTBEAT) 203 if (heartbeat < 1 || heartbeat > MAX_HEARTBEAT)
206 heartbeat = DEFAULT_HEARTBEAT; 204 heartbeat = DEFAULT_HEARTBEAT;
207 205
diff --git a/drivers/watchdog/i6300esb.c b/drivers/watchdog/i6300esb.c
index f236954d2536..ca44fd9b19bb 100644
--- a/drivers/watchdog/i6300esb.c
+++ b/drivers/watchdog/i6300esb.c
@@ -77,7 +77,7 @@
77 77
78/* internal variables */ 78/* internal variables */
79static void __iomem *BASEADDR; 79static void __iomem *BASEADDR;
80static spinlock_t esb_lock; /* Guards the hardware */ 80static DEFINE_SPINLOCK(esb_lock); /* Guards the hardware */
81static unsigned long timer_alive; 81static unsigned long timer_alive;
82static struct pci_dev *esb_pci; 82static struct pci_dev *esb_pci;
83static unsigned short triggered; /* The status of the watchdog upon boot */ 83static unsigned short triggered; /* The status of the watchdog upon boot */
@@ -456,8 +456,6 @@ static int __init watchdog_init (void)
456{ 456{
457 int ret; 457 int ret;
458 458
459 spin_lock_init(&esb_lock);
460
461 /* Check whether or not the hardware watchdog is there */ 459 /* Check whether or not the hardware watchdog is there */
462 if (!esb_getdevice () || esb_pci == NULL) 460 if (!esb_getdevice () || esb_pci == NULL)
463 return -ENODEV; 461 return -ENODEV;
diff --git a/drivers/watchdog/ib700wdt.c b/drivers/watchdog/ib700wdt.c
index c3a60f52ccb9..4b89f401691a 100644
--- a/drivers/watchdog/ib700wdt.c
+++ b/drivers/watchdog/ib700wdt.c
@@ -48,7 +48,7 @@
48 48
49static struct platform_device *ibwdt_platform_device; 49static struct platform_device *ibwdt_platform_device;
50static unsigned long ibwdt_is_open; 50static unsigned long ibwdt_is_open;
51static spinlock_t ibwdt_lock; 51static DEFINE_SPINLOCK(ibwdt_lock);
52static char expect_close; 52static char expect_close;
53 53
54/* Module information */ 54/* Module information */
@@ -308,8 +308,6 @@ static int __devinit ibwdt_probe(struct platform_device *dev)
308{ 308{
309 int res; 309 int res;
310 310
311 spin_lock_init(&ibwdt_lock);
312
313#if WDT_START != WDT_STOP 311#if WDT_START != WDT_STOP
314 if (!request_region(WDT_STOP, 1, "IB700 WDT")) { 312 if (!request_region(WDT_STOP, 1, "IB700 WDT")) {
315 printk (KERN_ERR PFX "STOP method I/O %X is not available.\n", WDT_STOP); 313 printk (KERN_ERR PFX "STOP method I/O %X is not available.\n", WDT_STOP);
diff --git a/drivers/watchdog/machzwd.c b/drivers/watchdog/machzwd.c
index 6d35bb112a5f..e6e07b4575eb 100644
--- a/drivers/watchdog/machzwd.c
+++ b/drivers/watchdog/machzwd.c
@@ -123,8 +123,8 @@ static void zf_ping(unsigned long data);
123static int zf_action = GEN_RESET; 123static int zf_action = GEN_RESET;
124static unsigned long zf_is_open; 124static unsigned long zf_is_open;
125static char zf_expect_close; 125static char zf_expect_close;
126static spinlock_t zf_lock; 126static DEFINE_SPINLOCK(zf_lock);
127static spinlock_t zf_port_lock; 127static DEFINE_SPINLOCK(zf_port_lock);
128static DEFINE_TIMER(zf_timer, zf_ping, 0, 0); 128static DEFINE_TIMER(zf_timer, zf_ping, 0, 0);
129static unsigned long next_heartbeat = 0; 129static unsigned long next_heartbeat = 0;
130 130
@@ -438,9 +438,6 @@ static int __init zf_init(void)
438 438
439 zf_show_action(action); 439 zf_show_action(action);
440 440
441 spin_lock_init(&zf_lock);
442 spin_lock_init(&zf_port_lock);
443
444 if(!request_region(ZF_IOBASE, 3, "MachZ ZFL WDT")){ 441 if(!request_region(ZF_IOBASE, 3, "MachZ ZFL WDT")){
445 printk(KERN_ERR "cannot reserve I/O ports at %d\n", 442 printk(KERN_ERR "cannot reserve I/O ports at %d\n",
446 ZF_IOBASE); 443 ZF_IOBASE);
diff --git a/drivers/watchdog/mpc83xx_wdt.c b/drivers/watchdog/mpc83xx_wdt.c
index a0bf95fb9763..6369f569517f 100644
--- a/drivers/watchdog/mpc83xx_wdt.c
+++ b/drivers/watchdog/mpc83xx_wdt.c
@@ -56,7 +56,7 @@ static int prescale = 1;
56static unsigned int timeout_sec; 56static unsigned int timeout_sec;
57 57
58static unsigned long wdt_is_open; 58static unsigned long wdt_is_open;
59static spinlock_t wdt_spinlock; 59static DEFINE_SPINLOCK(wdt_spinlock);
60 60
61static void mpc83xx_wdt_keepalive(void) 61static void mpc83xx_wdt_keepalive(void)
62{ 62{
@@ -185,9 +185,6 @@ static int __devinit mpc83xx_wdt_probe(struct platform_device *dev)
185 printk(KERN_INFO "WDT driver for MPC83xx initialized. " 185 printk(KERN_INFO "WDT driver for MPC83xx initialized. "
186 "mode:%s timeout=%d (%d seconds)\n", 186 "mode:%s timeout=%d (%d seconds)\n",
187 reset ? "reset":"interrupt", timeout, timeout_sec); 187 reset ? "reset":"interrupt", timeout, timeout_sec);
188
189 spin_lock_init(&wdt_spinlock);
190
191 return 0; 188 return 0;
192 189
193err_unmap: 190err_unmap:
diff --git a/drivers/watchdog/pc87413_wdt.c b/drivers/watchdog/pc87413_wdt.c
index 3d3deae0d64b..15e4f8887a9e 100644
--- a/drivers/watchdog/pc87413_wdt.c
+++ b/drivers/watchdog/pc87413_wdt.c
@@ -61,7 +61,7 @@ static unsigned long timer_enabled = 0; /* is the timer enabled? */
61 61
62static char expect_close; /* is the close expected? */ 62static char expect_close; /* is the close expected? */
63 63
64static spinlock_t io_lock; /* to guard the watchdog from io races */ 64static DEFINE_SPINLOCK(io_lock);/* to guard the watchdog from io races */
65 65
66static int nowayout = WATCHDOG_NOWAYOUT; 66static int nowayout = WATCHDOG_NOWAYOUT;
67 67
@@ -561,8 +561,6 @@ static int __init pc87413_init(void)
561{ 561{
562 int ret; 562 int ret;
563 563
564 spin_lock_init(&io_lock);
565
566 printk(KERN_INFO PFX "Version " VERSION " at io 0x%X\n", WDT_INDEX_IO_PORT); 564 printk(KERN_INFO PFX "Version " VERSION " at io 0x%X\n", WDT_INDEX_IO_PORT);
567 565
568 /* request_region(io, 2, "pc87413"); */ 566 /* request_region(io, 2, "pc87413"); */
diff --git a/drivers/watchdog/pnx4008_wdt.c b/drivers/watchdog/pnx4008_wdt.c
index b0eb9f9b43c7..b04aa096a10a 100644
--- a/drivers/watchdog/pnx4008_wdt.c
+++ b/drivers/watchdog/pnx4008_wdt.c
@@ -80,7 +80,7 @@
80static int nowayout = WATCHDOG_NOWAYOUT; 80static int nowayout = WATCHDOG_NOWAYOUT;
81static int heartbeat = DEFAULT_HEARTBEAT; 81static int heartbeat = DEFAULT_HEARTBEAT;
82 82
83static spinlock_t io_lock; 83static DEFINE_SPINLOCK(io_lock);
84static unsigned long wdt_status; 84static unsigned long wdt_status;
85#define WDT_IN_USE 0 85#define WDT_IN_USE 0
86#define WDT_OK_TO_CLOSE 1 86#define WDT_OK_TO_CLOSE 1
@@ -254,8 +254,6 @@ static int pnx4008_wdt_probe(struct platform_device *pdev)
254 int ret = 0, size; 254 int ret = 0, size;
255 struct resource *res; 255 struct resource *res;
256 256
257 spin_lock_init(&io_lock);
258
259 if (heartbeat < 1 || heartbeat > MAX_HEARTBEAT) 257 if (heartbeat < 1 || heartbeat > MAX_HEARTBEAT)
260 heartbeat = DEFAULT_HEARTBEAT; 258 heartbeat = DEFAULT_HEARTBEAT;
261 259
diff --git a/drivers/watchdog/sbc8360.c b/drivers/watchdog/sbc8360.c
index 285d85289532..2ee2677f3648 100644
--- a/drivers/watchdog/sbc8360.c
+++ b/drivers/watchdog/sbc8360.c
@@ -54,7 +54,7 @@
54#include <asm/system.h> 54#include <asm/system.h>
55 55
56static unsigned long sbc8360_is_open; 56static unsigned long sbc8360_is_open;
57static spinlock_t sbc8360_lock; 57static DEFINE_SPINLOCK(sbc8360_lock);
58static char expect_close; 58static char expect_close;
59 59
60#define PFX "sbc8360: " 60#define PFX "sbc8360: "
@@ -359,7 +359,6 @@ static int __init sbc8360_init(void)
359 goto out_noreboot; 359 goto out_noreboot;
360 } 360 }
361 361
362 spin_lock_init(&sbc8360_lock);
363 res = misc_register(&sbc8360_miscdev); 362 res = misc_register(&sbc8360_miscdev);
364 if (res) { 363 if (res) {
365 printk(KERN_ERR PFX "failed to register misc device\n"); 364 printk(KERN_ERR PFX "failed to register misc device\n");
diff --git a/drivers/watchdog/sc1200wdt.c b/drivers/watchdog/sc1200wdt.c
index 9670d47190d0..32ccd7c89c7d 100644
--- a/drivers/watchdog/sc1200wdt.c
+++ b/drivers/watchdog/sc1200wdt.c
@@ -74,7 +74,7 @@ static int io = -1;
74static int io_len = 2; /* for non plug and play */ 74static int io_len = 2; /* for non plug and play */
75static struct semaphore open_sem; 75static struct semaphore open_sem;
76static char expect_close; 76static char expect_close;
77static spinlock_t sc1200wdt_lock; /* io port access serialisation */ 77static DEFINE_SPINLOCK(sc1200wdt_lock); /* io port access serialisation */
78 78
79#if defined CONFIG_PNP 79#if defined CONFIG_PNP
80static int isapnp = 1; 80static int isapnp = 1;
@@ -375,7 +375,6 @@ static int __init sc1200wdt_init(void)
375 375
376 printk("%s\n", banner); 376 printk("%s\n", banner);
377 377
378 spin_lock_init(&sc1200wdt_lock);
379 sema_init(&open_sem, 1); 378 sema_init(&open_sem, 1);
380 379
381#if defined CONFIG_PNP 380#if defined CONFIG_PNP
diff --git a/drivers/watchdog/sc520_wdt.c b/drivers/watchdog/sc520_wdt.c
index e8594c64d1e6..2847324a2be2 100644
--- a/drivers/watchdog/sc520_wdt.c
+++ b/drivers/watchdog/sc520_wdt.c
@@ -125,7 +125,7 @@ static DEFINE_TIMER(timer, wdt_timer_ping, 0, 0);
125static unsigned long next_heartbeat; 125static unsigned long next_heartbeat;
126static unsigned long wdt_is_open; 126static unsigned long wdt_is_open;
127static char wdt_expect_close; 127static char wdt_expect_close;
128static spinlock_t wdt_spinlock; 128static DEFINE_SPINLOCK(wdt_spinlock);
129 129
130/* 130/*
131 * Whack the dog 131 * Whack the dog
@@ -383,8 +383,6 @@ static int __init sc520_wdt_init(void)
383{ 383{
384 int rc = -EBUSY; 384 int rc = -EBUSY;
385 385
386 spin_lock_init(&wdt_spinlock);
387
388 /* Check that the timeout value is within it's range ; if not reset to the default */ 386 /* Check that the timeout value is within it's range ; if not reset to the default */
389 if (wdt_set_heartbeat(timeout)) { 387 if (wdt_set_heartbeat(timeout)) {
390 wdt_set_heartbeat(WATCHDOG_TIMEOUT); 388 wdt_set_heartbeat(WATCHDOG_TIMEOUT);
diff --git a/drivers/watchdog/smsc37b787_wdt.c b/drivers/watchdog/smsc37b787_wdt.c
index d3cb0a766020..5d2b5ba61414 100644
--- a/drivers/watchdog/smsc37b787_wdt.c
+++ b/drivers/watchdog/smsc37b787_wdt.c
@@ -83,7 +83,7 @@ static unsigned long timer_enabled = 0; /* is the timer enabled? */
83 83
84static char expect_close; /* is the close expected? */ 84static char expect_close; /* is the close expected? */
85 85
86static spinlock_t io_lock; /* to guard the watchdog from io races */ 86static DEFINE_SPINLOCK(io_lock);/* to guard the watchdog from io races */
87 87
88static int nowayout = WATCHDOG_NOWAYOUT; 88static int nowayout = WATCHDOG_NOWAYOUT;
89 89
@@ -540,8 +540,6 @@ static int __init wb_smsc_wdt_init(void)
540{ 540{
541 int ret; 541 int ret;
542 542
543 spin_lock_init(&io_lock);
544
545 printk("SMsC 37B787 watchdog component driver " VERSION " initialising...\n"); 543 printk("SMsC 37B787 watchdog component driver " VERSION " initialising...\n");
546 544
547 if (!request_region(IOPORT, IOPORT_SIZE, "SMsC 37B787 watchdog")) { 545 if (!request_region(IOPORT, IOPORT_SIZE, "SMsC 37B787 watchdog")) {
diff --git a/drivers/watchdog/w83627hf_wdt.c b/drivers/watchdog/w83627hf_wdt.c
index df33b3b5a53c..386492821fc2 100644
--- a/drivers/watchdog/w83627hf_wdt.c
+++ b/drivers/watchdog/w83627hf_wdt.c
@@ -48,7 +48,7 @@
48 48
49static unsigned long wdt_is_open; 49static unsigned long wdt_is_open;
50static char expect_close; 50static char expect_close;
51static spinlock_t io_lock; 51static DEFINE_SPINLOCK(io_lock);
52 52
53/* You must set this - there is no sane way to probe for this board. */ 53/* You must set this - there is no sane way to probe for this board. */
54static int wdt_io = 0x2E; 54static int wdt_io = 0x2E;
@@ -328,8 +328,6 @@ wdt_init(void)
328{ 328{
329 int ret; 329 int ret;
330 330
331 spin_lock_init(&io_lock);
332
333 printk(KERN_INFO "WDT driver for the Winbond(TM) W83627HF/THF/HG Super I/O chip initialising.\n"); 331 printk(KERN_INFO "WDT driver for the Winbond(TM) W83627HF/THF/HG Super I/O chip initialising.\n");
334 332
335 if (wdt_set_heartbeat(timeout)) { 333 if (wdt_set_heartbeat(timeout)) {
diff --git a/drivers/watchdog/w83697hf_wdt.c b/drivers/watchdog/w83697hf_wdt.c
index 51826c216d6d..c622a0e6c9ae 100644
--- a/drivers/watchdog/w83697hf_wdt.c
+++ b/drivers/watchdog/w83697hf_wdt.c
@@ -47,7 +47,7 @@
47 47
48static unsigned long wdt_is_open; 48static unsigned long wdt_is_open;
49static char expect_close; 49static char expect_close;
50static spinlock_t io_lock; 50static DEFINE_SPINLOCK(io_lock);
51 51
52/* You must set this - there is no sane way to probe for this board. */ 52/* You must set this - there is no sane way to probe for this board. */
53static int wdt_io = 0x2e; 53static int wdt_io = 0x2e;
@@ -376,8 +376,6 @@ wdt_init(void)
376{ 376{
377 int ret, i, found = 0; 377 int ret, i, found = 0;
378 378
379 spin_lock_init(&io_lock);
380
381 printk (KERN_INFO PFX "WDT driver for W83697HF/HG initializing\n"); 379 printk (KERN_INFO PFX "WDT driver for W83697HF/HG initializing\n");
382 380
383 if (wdt_io == 0) { 381 if (wdt_io == 0) {
diff --git a/drivers/watchdog/w83877f_wdt.c b/drivers/watchdog/w83877f_wdt.c
index 3c88fe18f4f4..bcc9d48955de 100644
--- a/drivers/watchdog/w83877f_wdt.c
+++ b/drivers/watchdog/w83877f_wdt.c
@@ -94,7 +94,7 @@ static DEFINE_TIMER(timer, wdt_timer_ping, 0, 0);
94static unsigned long next_heartbeat; 94static unsigned long next_heartbeat;
95static unsigned long wdt_is_open; 95static unsigned long wdt_is_open;
96static char wdt_expect_close; 96static char wdt_expect_close;
97static spinlock_t wdt_spinlock; 97static DEFINE_SPINLOCK(wdt_spinlock);
98 98
99/* 99/*
100 * Whack the dog 100 * Whack the dog
@@ -350,8 +350,6 @@ static int __init w83877f_wdt_init(void)
350{ 350{
351 int rc = -EBUSY; 351 int rc = -EBUSY;
352 352
353 spin_lock_init(&wdt_spinlock);
354
355 if(timeout < 1 || timeout > 3600) /* arbitrary upper limit */ 353 if(timeout < 1 || timeout > 3600) /* arbitrary upper limit */
356 { 354 {
357 timeout = WATCHDOG_TIMEOUT; 355 timeout = WATCHDOG_TIMEOUT;
diff --git a/drivers/watchdog/w83977f_wdt.c b/drivers/watchdog/w83977f_wdt.c
index 157968442891..b475529d2475 100644
--- a/drivers/watchdog/w83977f_wdt.c
+++ b/drivers/watchdog/w83977f_wdt.c
@@ -50,7 +50,7 @@ static int timeoutW; /* timeout in watchdog counter units */
50static unsigned long timer_alive; 50static unsigned long timer_alive;
51static int testmode; 51static int testmode;
52static char expect_close; 52static char expect_close;
53static spinlock_t spinlock; 53static DEFINE_SPINLOCK(spinlock);
54 54
55module_param(timeout, int, 0); 55module_param(timeout, int, 0);
56MODULE_PARM_DESC(timeout,"Watchdog timeout in seconds (15..7635), default=" __MODULE_STRING(DEFAULT_TIMEOUT) ")"); 56MODULE_PARM_DESC(timeout,"Watchdog timeout in seconds (15..7635), default=" __MODULE_STRING(DEFAULT_TIMEOUT) ")");
@@ -476,8 +476,6 @@ static int __init w83977f_wdt_init(void)
476 476
477 printk(KERN_INFO PFX DRIVER_VERSION); 477 printk(KERN_INFO PFX DRIVER_VERSION);
478 478
479 spin_lock_init(&spinlock);
480
481 /* 479 /*
482 * Check that the timeout value is within it's range ; 480 * Check that the timeout value is within it's range ;
483 * if not reset to the default 481 * if not reset to the default
diff --git a/drivers/watchdog/wafer5823wdt.c b/drivers/watchdog/wafer5823wdt.c
index 950905d3c39f..9e368091f799 100644
--- a/drivers/watchdog/wafer5823wdt.c
+++ b/drivers/watchdog/wafer5823wdt.c
@@ -45,7 +45,7 @@
45 45
46static unsigned long wafwdt_is_open; 46static unsigned long wafwdt_is_open;
47static char expect_close; 47static char expect_close;
48static spinlock_t wafwdt_lock; 48static DEFINE_SPINLOCK(wafwdt_lock);
49 49
50/* 50/*
51 * You must set these - there is no sane way to probe for this board. 51 * You must set these - there is no sane way to probe for this board.
@@ -252,8 +252,6 @@ static int __init wafwdt_init(void)
252 252
253 printk(KERN_INFO "WDT driver for Wafer 5823 single board computer initialising.\n"); 253 printk(KERN_INFO "WDT driver for Wafer 5823 single board computer initialising.\n");
254 254
255 spin_lock_init(&wafwdt_lock);
256
257 if (timeout < 1 || timeout > 255) { 255 if (timeout < 1 || timeout > 255) {
258 timeout = WD_TIMO; 256 timeout = WD_TIMO;
259 printk (KERN_INFO PFX "timeout value must be 1<=x<=255, using %d\n", 257 printk (KERN_INFO PFX "timeout value must be 1<=x<=255, using %d\n",
diff --git a/drivers/watchdog/wdt977.c b/drivers/watchdog/wdt977.c
index 7d300ff7ab07..9b7f6b6edef6 100644
--- a/drivers/watchdog/wdt977.c
+++ b/drivers/watchdog/wdt977.c
@@ -59,7 +59,7 @@ static int timeoutM; /* timeout in minutes */
59static unsigned long timer_alive; 59static unsigned long timer_alive;
60static int testmode; 60static int testmode;
61static char expect_close; 61static char expect_close;
62static spinlock_t spinlock; 62static DEFINE_SPINLOCK(spinlock);
63 63
64module_param(timeout, int, 0); 64module_param(timeout, int, 0);
65MODULE_PARM_DESC(timeout,"Watchdog timeout in seconds (60..15300), default=" __MODULE_STRING(DEFAULT_TIMEOUT) ")"); 65MODULE_PARM_DESC(timeout,"Watchdog timeout in seconds (60..15300), default=" __MODULE_STRING(DEFAULT_TIMEOUT) ")");
@@ -448,8 +448,6 @@ static int __init wd977_init(void)
448 448
449 printk(KERN_INFO PFX DRIVER_VERSION); 449 printk(KERN_INFO PFX DRIVER_VERSION);
450 450
451 spin_lock_init(&spinlock);
452
453 /* Check that the timeout value is within it's range ; if not reset to the default */ 451 /* Check that the timeout value is within it's range ; if not reset to the default */
454 if (wdt977_set_timeout(timeout)) 452 if (wdt977_set_timeout(timeout))
455 { 453 {
diff --git a/drivers/watchdog/wdt_pci.c b/drivers/watchdog/wdt_pci.c
index 6bfe0e29dc1a..1355608683e4 100644
--- a/drivers/watchdog/wdt_pci.c
+++ b/drivers/watchdog/wdt_pci.c
@@ -74,7 +74,7 @@
74static int dev_count; 74static int dev_count;
75 75
76static struct semaphore open_sem; 76static struct semaphore open_sem;
77static spinlock_t wdtpci_lock; 77static DEFINE_SPINLOCK(wdtpci_lock);
78static char expect_close; 78static char expect_close;
79 79
80static int io; 80static int io;
@@ -607,7 +607,6 @@ static int __devinit wdtpci_init_one (struct pci_dev *dev,
607 } 607 }
608 608
609 sema_init(&open_sem, 1); 609 sema_init(&open_sem, 1);
610 spin_lock_init(&wdtpci_lock);
611 610
612 irq = dev->irq; 611 irq = dev->irq;
613 io = pci_resource_start (dev, 2); 612 io = pci_resource_start (dev, 2);