]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
[PATCH] ipmi: fix watchdog so the device can be reopened on an unexpected close
authorCorey Minyard <minyard@acm.org>
Sun, 1 May 2005 15:59:11 +0000 (08:59 -0700)
committerLinus Torvalds <torvalds@ppc970.osdl.org>
Sun, 1 May 2005 15:59:11 +0000 (08:59 -0700)
If there is an unexpected close, still allow the watchdog interface to be
re-opened on the IPMI watchdog.

Signed-off-by: Corey Minyard <minyard@acm.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
drivers/char/ipmi/ipmi_watchdog.c

index fd7093879c6604934ac5d6308a07a39525e63aee..fcd1c02a32cb329e055c38406897e0d647e5173d 100644 (file)
@@ -709,11 +709,11 @@ static int ipmi_close(struct inode *ino, struct file *filep)
                if (expect_close == 42) {
                        ipmi_watchdog_state = WDOG_TIMEOUT_NONE;
                        ipmi_set_timeout(IPMI_SET_TIMEOUT_NO_HB);
-                       clear_bit(0, &ipmi_wdog_open);
                } else {
                        printk(KERN_CRIT PFX "Unexpected close, not stopping watchdog!\n");
                        ipmi_heartbeat();
                }
+               clear_bit(0, &ipmi_wdog_open);
        }
 
        ipmi_fasync (-1, filep, 0);