http://linux-watchdog.bkbits.net/linux-2.6-watchdog-mm castet.matthieu@free.fr|ChangeSet|20041029182005|45189 castet.matthieu # This is a BitKeeper generated diff -Nru style patch. # # ChangeSet # 2004/10/29 16:17:53-07:00 akpm@bix.(none) # Merge http://linux-watchdog.bkbits.net/linux-2.6-watchdog-mm # into bix.(none):/usr/src/bk-watchdog # # drivers/char/watchdog/i8xx_tco.c # 2004/10/29 16:17:49-07:00 akpm@bix.(none) +0 -0 # Auto merged # # ChangeSet # 2004/10/29 20:20:05+02:00 castet.matthieu@free.fr # [WATCHDOG] i8xx_tco.c-request_region-patch # # Fix: in i8xx_tco.c, during the initialisation, the driver accesses io # without checking if the port is free. # # drivers/char/watchdog/i8xx_tco.c # 2004/10/29 20:19:56+02:00 castet.matthieu@free.fr +10 -3 # Fix: in i8xx_tco.c, during the initialisation, the driver accesses io # without checking if the port is free. # # ChangeSet # 2004/10/21 00:32:07-07:00 akpm@bix.(none) # Merge bix.(none):/usr/src/bk25 into bix.(none):/usr/src/bk-watchdog # # drivers/char/watchdog/i8xx_tco.c # 2004/10/21 00:32:02-07:00 akpm@bix.(none) +0 -1 # Auto merged # # drivers/char/watchdog/Kconfig # 2004/10/21 00:32:02-07:00 akpm@bix.(none) +0 -0 # Auto merged # # ChangeSet # 2004/10/19 17:44:31-07:00 akpm@bix.(none) # Merge bix.(none):/usr/src/bk25 into bix.(none):/usr/src/bk-watchdog # # drivers/char/watchdog/Kconfig # 2004/10/19 17:44:27-07:00 akpm@bix.(none) +0 -0 # Auto merged # # ChangeSet # 2004/10/18 20:48:14+02:00 wim@iguana.be # [WATCHDOG] v2.6.9-rc3 i8xx_tco.c-stop_reboot-patch # # Fix for Bugzilla Bug 132719: "watchdog i8xx_tco causing machine to # reboot." # # drivers/char/watchdog/i8xx_tco.c # 2004/10/17 20:35:38+02:00 wim@iguana.be +1 -1 # Import patch i8xx_tco.c-patch # diff -Nru a/drivers/char/watchdog/i8xx_tco.c b/drivers/char/watchdog/i8xx_tco.c --- a/drivers/char/watchdog/i8xx_tco.c 2004-11-10 17:44:31 -08:00 +++ b/drivers/char/watchdog/i8xx_tco.c 2004-11-10 17:44:31 -08:00 @@ -415,12 +415,15 @@ } } /* Set the TCO_EN bit in SMI_EN register */ + if (!request_region (SMI_EN + 1, 1, "i8xx TCO")) { + printk (KERN_ERR PFX "I/O address 0x%04x already in use\n", + SMI_EN + 1); + return 0; + } val1 = inb (SMI_EN + 1); val1 &= 0xdf; outb (val1, SMI_EN + 1); - /* Clear out the (probably old) status */ - outb (0, TCO1_STS); - outb (3, TCO2_STS); + release_region (SMI_EN + 1, 1); return 1; } return 0; @@ -442,6 +445,10 @@ ret = -EIO; goto out; } + + /* Clear out the (probably old) status */ + outb (0, TCO1_STS); + outb (3, TCO2_STS); /* Check that the heartbeat value is within it's range ; if not reset to the default */ if (tco_timer_set_heartbeat (heartbeat)) {