* [PATCH] watchdog: Stop looking for device as soon as one is found
@ 2007-11-04 19:20 Samuel Tardieu
0 siblings, 0 replies; only message in thread
From: Samuel Tardieu @ 2007-11-04 19:20 UTC (permalink / raw)
To: Wim Van Sebroeck; +Cc: linux-kernel
If no address is given for the W83697HF/HG watchdog IO port, stop looping
through possible locations when a watchdog device has been found.
Signed-off-by: Samuel Tardieu <sam@rfc1149.net>
---
drivers/watchdog/w83697hf_wdt.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/drivers/watchdog/w83697hf_wdt.c b/drivers/watchdog/w83697hf_wdt.c
index c622a0e..6ea125e 100644
--- a/drivers/watchdog/w83697hf_wdt.c
+++ b/drivers/watchdog/w83697hf_wdt.c
@@ -382,8 +382,10 @@ wdt_init(void)
/* we will autodetect the W83697HF/HG watchdog */
for (i = 0; ((!found) && (w83697hf_ioports[i] != 0)); i++) {
wdt_io = w83697hf_ioports[i];
- if (!w83697hf_check_wdt())
+ if (!w83697hf_check_wdt()) {
found++;
+ break;
+ }
}
} else {
if (!w83697hf_check_wdt())
--
1.5.3.5
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2007-11-04 19:33 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-11-04 19:20 [PATCH] watchdog: Stop looking for device as soon as one is found Samuel Tardieu
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®