From f80e919bb42c191bbe60ab078a59b30336d11d3b Mon Sep 17 00:00:00 2001 From: Florian Fainelli Date: Fri, 24 Oct 2008 19:52:56 +0200 Subject: [PATCH] [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 Signed-off-by: Wim Van Sebroeck --- drivers/watchdog/mtx-1_wdt.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/watchdog/mtx-1_wdt.c b/drivers/watchdog/mtx-1_wdt.c index b4b7b0a..3acce62 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; -- 2.7.4