[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <4ed01ce0.pLO/jX2YTtsMsYc8%marc.vertes@sigfox.com>
Date: Fri, 25 Nov 2011 23:55:28 +0100
From: Marc Vertes <marc.vertes@...fox.com>
To: Wim Van Sebroeck <wim@...ana.be>
Cc: linux-kernel@...r.kernel.org, linux-watchdog@...r.kernel.org,
Mark Brown <broonie@...nsource.wolfsonmicro.com>
Subject: [PATCH] watchdog: fix nowayout setting in wm831x_wdt
Use set_bit() to set the nowayout flag, as WDOG_NO_WAY_OUT is a
bit number, not a mask. It avoids corruption of status flag.
Signed-off-by: Marc Vertes <marc.vertes@...fox.com>
---
wm831x_wdt.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- linux-3.2-rc3/drivers/watchdog/wm831x_wdt.c.orig 2011-11-24 05:20:28.000000000 +0100
+++ linux-3.2-rc3/drivers/watchdog/wm831x_wdt.c 2011-11-25 23:22:22.447258730 +0100
@@ -216,7 +216,7 @@ static int __devinit wm831x_wdt_probe(st
watchdog_set_drvdata(wm831x_wdt, driver_data);
if (nowayout)
- wm831x_wdt->status |= WDOG_NO_WAY_OUT;
+ setbit(WDOG_NO_WAY_OUT, &wm831x_wdt->status);
reg = wm831x_reg_read(wm831x, WM831X_WATCHDOG);
reg &= WM831X_WDOG_TO_MASK;
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists