From 73639e27170355a2bb9a54a340f5bcd2f3dac161 Mon Sep 17 00:00:00 2001 From: Alexandru Gagniuc Date: Wed, 9 Apr 2014 12:24:39 -0500 Subject: hp/pavilion_m6_1035dx: Add SMI handler and handle EC requests The EC may disable some functionality, such as Caps Lock LED and battery charging if it never receives a command to go in APM mode. If we start it in APM mode, then immediately switch to ACPI mode, it will not get its SCIs serviced until an ACPI OS boots. If its SCIs are not serviced, it may assume the OS has hung. The way we solve this is to initalize the EC in APM mode, and only switch it to ACPI when an ACPI-capable OS issues the ACPI_ENABLE command. The switch has to be handled in SMM. Although we aren't yet processing SMIs from the EC, we are reading the status in order to satisfy the EC that the event is handled. Change-Id: Iffaeb9a6f57841f456c4bce8337dc09b287f8758 Signed-off-by: Alexandru Gagniuc Reviewed-on: http://review.coreboot.org/5512 Tested-by: build bot (Jenkins) Reviewed-by: Paul Menzel Reviewed-by: Aaron Durbin --- src/mainboard/hp/pavilion_m6_1035dx/mainboard.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/mainboard/hp/pavilion_m6_1035dx/mainboard.c') diff --git a/src/mainboard/hp/pavilion_m6_1035dx/mainboard.c b/src/mainboard/hp/pavilion_m6_1035dx/mainboard.c index 2e2b72bf03..756b443b5e 100644 --- a/src/mainboard/hp/pavilion_m6_1035dx/mainboard.c +++ b/src/mainboard/hp/pavilion_m6_1035dx/mainboard.c @@ -30,6 +30,8 @@ #include #include +#include + /************************************************* * enable the dedicated function in parmer board. *************************************************/ @@ -39,6 +41,9 @@ static void mainboard_enable(device_t dev) pavilion_m6_1035dx_ec_init(); + hudson_enable_gevent_smi(EC_SMI_GEVENT); + hudson_enable_smi_generation(); + /* * The mainboard is the first place that we get control in ramstage. Check * for S3 resume and call the approriate AGESA/CIMx resume functions. -- cgit v1.2.3