]> git.karo-electronics.de Git - mv-sheeva.git/commitdiff
[WATCHDOG] iTCO_wdt : correct status clearing
authorWim Van Sebroeck <wim@iguana.be>
Wed, 19 Nov 2008 20:02:02 +0000 (20:02 +0000)
committerWim Van Sebroeck <wim@iguana.be>
Fri, 21 Nov 2008 08:34:32 +0000 (08:34 +0000)
The iTCO_wdt code was not clearing the correct bits.
It now clears the timeout status bit and then the
SECOND_TO_STS bit and then the BOOT_STS bit.
Note: we should first clear the SECOND_TO_STS bit
before clearing the BOOT_STS bit.

Signed-off-by: Wim Van Sebroeck <wim@iguana.be>
drivers/watchdog/iTCO_wdt.c

index 75483000a87d7eabd5b7b0f5ffeaa44550bc582f..2b5409f5b4e67b02d3677e4037c0c1e22f6a9d75 100644 (file)
@@ -684,8 +684,9 @@ static int __devinit iTCO_wdt_init(struct pci_dev *pdev,
                        TCOBASE);
 
        /* Clear out the (probably old) status */
-       outb(0, TCO1_STS);
-       outb(3, TCO2_STS);
+       outb(8, TCO1_STS);      /* Clear the Time Out Status bit */
+       outb(2, TCO2_STS);      /* Clear SECOND_TO_STS bit */
+       outb(4, TCO2_STS);      /* Clear BOOT_STS bit */
 
        /* Make sure the watchdog is not running */
        iTCO_wdt_stop();