Author: stepan
Date: Sun Aug 15 13:37:41 2010
New Revision: 5697
URL: https://tracker.coreboot.org/trac/coreboot/changeset/5697

Log:
Gigabyte dual bios mainboard will always reboot, caused by the superio. 
After lots of testing, the SuperIO LDN 7, register 0xEF is the key to the
problem. This patch adds a function which stops dual bios mainboards from
rebooting, when called.

Signed-off-by: Wang Qing Pei <wangqing...@gmail.com>
Acked-by: Stefan Reinauer <ste...@coresystems.de>

Modified:
   trunk/src/superio/ite/it8718f/it8718f.h
   trunk/src/superio/ite/it8718f/it8718f_early_serial.c

Modified: trunk/src/superio/ite/it8718f/it8718f.h
==============================================================================
--- trunk/src/superio/ite/it8718f/it8718f.h     Sat Aug 14 22:38:17 2010        
(r5696)
+++ trunk/src/superio/ite/it8718f/it8718f.h     Sun Aug 15 13:37:41 2010        
(r5697)
@@ -32,6 +32,7 @@
 
 #if defined(__PRE_RAM__) && !defined(__ROMCC__)
 void it8718f_24mhz_clkin(void);
+void it8718f_disable_reboot(void);
 void it8718f_enable_serial(device_t dev, unsigned iobase);
 #endif
 

Modified: trunk/src/superio/ite/it8718f/it8718f_early_serial.c
==============================================================================
--- trunk/src/superio/ite/it8718f/it8718f_early_serial.c        Sat Aug 14 
22:38:17 2010        (r5696)
+++ trunk/src/superio/ite/it8718f/it8718f_early_serial.c        Sun Aug 15 
13:37:41 2010        (r5697)
@@ -74,6 +74,20 @@
        it8718f_exit_conf();
 }
 
+/* GIGABYTE uses a special SuperIO register to protect its Dual BIOS
+ * mechanism. It lives in the GPIO LDN. However, register 0xEF is not
+ * mentioned in the IT8718F datasheet so just hardcode it to 0x7E for
+ * now.
+ */
+void it8718f_disable_reboot(void)
+{
+       it8718f_enter_conf();
+
+       it8718f_sio_write(0x07, 0xEF, 0x7E);
+
+       it8718f_exit_conf();
+}
+
 /* Enable the peripheral devices on the IT8718F Super I/O chip. */
 void it8718f_enable_serial(device_t dev, unsigned iobase)
 {

-- 
coreboot mailing list: coreboot@coreboot.org
http://www.coreboot.org/mailman/listinfo/coreboot

Reply via email to