diff options
author | Florian Fainelli <florian@openwrt.org> | 2008-10-24 19:52:56 +0200 |
---|---|---|
committer | Wim Van Sebroeck <wim@iguana.be> | 2008-11-21 08:20:49 +0000 |
commit | f80e919bb42c191bbe60ab078a59b30336d11d3b (patch) | |
tree | 0dbbd9a819ff724be7fc6723c50f1c8405499969 /drivers/watchdog | |
parent | ed313489badef16d700f5a3be50e8fd8f8294bc8 (diff) | |
download | blackbird-op-linux-f80e919bb42c191bbe60ab078a59b30336d11d3b.tar.gz blackbird-op-linux-f80e919bb42c191bbe60ab078a59b30336d11d3b.zip |
[WATCHDOG] fix mtx1_wdt compilation failure
Using spin_lock_irqsave with a local variable called flags without
declaring is a bad idea, fix this by declaring it.
Signed-off-by: Florian Fainelli <florian@openwrt.org>
Signed-off-by: Wim Van Sebroeck <wim@iguana.be>
Diffstat (limited to 'drivers/watchdog')
-rw-r--r-- | drivers/watchdog/mtx-1_wdt.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/watchdog/mtx-1_wdt.c b/drivers/watchdog/mtx-1_wdt.c index b4b7b0a4c119..3acce623f209 100644 --- a/drivers/watchdog/mtx-1_wdt.c +++ b/drivers/watchdog/mtx-1_wdt.c @@ -98,6 +98,8 @@ static void mtx1_wdt_reset(void) static void mtx1_wdt_start(void) { + unsigned long flags; + spin_lock_irqsave(&mtx1_wdt_device.lock, flags); if (!mtx1_wdt_device.queue) { mtx1_wdt_device.queue = 1; @@ -110,6 +112,8 @@ static void mtx1_wdt_start(void) static int mtx1_wdt_stop(void) { + unsigned long flags; + spin_lock_irqsave(&mtx1_wdt_device.lock, flags); if (mtx1_wdt_device.queue) { mtx1_wdt_device.queue = 0; |