From 9c3e90d6a1086754c6899792dd3d8e19c0c8c03e Mon Sep 17 00:00:00 2001 From: Vadim Bendebury Date: Thu, 15 Mar 2012 21:36:12 -0700 Subject: Use keyboard controller for hard reset instead of CF9 For some still unknown reason writes to localtion 0xcf9 do not cause the Link to reboot, they cause it to shut down instead. While this will have to be investigated and fixed, this change modifies the code to use the keyboard controller (implemented by the EC on Link) to restart the system. Once the 0xcf9 problem is resolved, this change could be reverted. BUG=chrome-os-partner:8397 TEST=manual . when u-boot tires restarting the system it now reboots. before this change it would just shut down. Change-Id: I8076f897304f705e20ec8f2e30cce17d7fdd31c4 Signed-off-by: Vadim Bendebury Reviewed-on: https://gerrit.chromium.org/gerrit/18332 Reviewed-by: Hung-Te Lin --- board/chromebook-x86/chromeos/power_management.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/board/chromebook-x86/chromeos/power_management.c b/board/chromebook-x86/chromeos/power_management.c index 2910f3a0a1..40116a24f9 100644 --- a/board/chromebook-x86/chromeos/power_management.c +++ b/board/chromebook-x86/chromeos/power_management.c @@ -14,6 +14,7 @@ #include #include #include +#include #include #define PM1_STS 0x00 @@ -57,9 +58,14 @@ int is_processor_reset(void) void cold_reboot(void) { printf("Rebooting...\n"); + + /* let's use keyboard controller for this */ + outb(0xfe, KBDCMD); + /* + TODO(vbendeb): fix CF9 reset and use it instead of KB reset outb(SYS_RST, RST_CNT); outb(SYS_RST | RST_CPU, RST_CNT); - + */ for (;;) asm("hlt"); } -- cgit v1.2.3