summaryrefslogtreecommitdiff
path: root/src/southbridge
diff options
context:
space:
mode:
authorAndrew Wu <arw@dmp.com.tw>2013-10-19 01:33:08 +0800
committerStefan Reinauer <stefan.reinauer@coreboot.org>2013-10-22 22:48:34 +0200
commit1ce4860405d995585d08350481932238ee2f8c4a (patch)
treed1405ca509ff1c54de6301fa1911f6e3f114d96b /src/southbridge
parentac164057993e9edbfe78537efbbc9ef5f75cd67c (diff)
downloadcoreboot-1ce4860405d995585d08350481932238ee2f8c4a.tar.xz
vortex86ex: Defer checking PS/2 keyboard controller system flag
Don't check keyboard controller system flag until before calling pc_keyboard_init(). This makes waiting time shorter. Change-Id: I2cdb533a5b25575e1717434533a60decf748f6d8 Signed-off-by: Andrew Wu <arw@dmp.com.tw> Reviewed-on: http://review.coreboot.org/3958 Tested-by: build bot (Jenkins) Reviewed-by: Ronald G. Minnich <rminnich@gmail.com>
Diffstat (limited to 'src/southbridge')
-rw-r--r--src/southbridge/dmp/vortex86ex/southbridge.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/southbridge/dmp/vortex86ex/southbridge.c b/src/southbridge/dmp/vortex86ex/southbridge.c
index d8914c0a41..ddb99b8241 100644
--- a/src/southbridge/dmp/vortex86ex/southbridge.c
+++ b/src/southbridge/dmp/vortex86ex/southbridge.c
@@ -138,7 +138,13 @@ static void upload_dmp_keyboard_firmware(struct device *dev)
// disable firmware uploading.
pci_write_config32(dev, SB_REG_IPFCR, reg_sb_c0 & ~0x400L);
- // wait keyboard controller ready by checking status port bit 2.
+}
+
+static void kbc_wait_system_flag(void)
+{
+ /* wait keyboard controller ready by checking system flag
+ * (status port bit 2).
+ */
post_code(POST_KBD_CHK_READY);
while ((inb(0x64) & 0x4) == 0) {
}
@@ -571,6 +577,7 @@ static void southbridge_init(struct device *dev)
fix_cmos_rtc_time();
rtc_init(0);
+ kbc_wait_system_flag();
pc_keyboard_init(0);
}