mirror of
https://github.com/Telecominfraproject/OpenCellular.git
synced 2026-01-09 00:51:29 +00:00
x86power module must init before power button module
The power button module now needs to know whether the chipset is in the on state at init-time, in which case it doesn't need to send a power button pulse to the chipset. BUG=chrome-os-partner:11085 TEST=manual 1. power on AP to BIOS screen (e.g., in recovery mode) 2. At EC console, 'sysjump A' 3. system should stay powered on Signed-off-by: Randall Spangler <rspangler@chromium.org> Change-Id: Ic1f509204f502d1ddf87314f0e1582c21c991156 Reviewed-on: https://gerrit.chromium.org/gerrit/26700 Reviewed-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
@@ -535,7 +535,7 @@ static int power_button_init(void)
|
||||
|
||||
return EC_SUCCESS;
|
||||
}
|
||||
DECLARE_HOOK(HOOK_INIT, power_button_init, HOOK_PRIO_DEFAULT);
|
||||
DECLARE_HOOK(HOOK_INIT, power_button_init, HOOK_PRIO_DEFAULT + 1);
|
||||
|
||||
|
||||
void power_button_interrupt(enum gpio_signal signal)
|
||||
|
||||
@@ -393,14 +393,13 @@ static int x86_power_init(void)
|
||||
|
||||
return EC_SUCCESS;
|
||||
}
|
||||
DECLARE_HOOK(HOOK_INIT, x86_power_init, HOOK_PRIO_DEFAULT);
|
||||
|
||||
/*****************************************************************************/
|
||||
/* Task function */
|
||||
|
||||
void x86_power_task(void)
|
||||
{
|
||||
x86_power_init();
|
||||
|
||||
while (1) {
|
||||
CPRINTF("[%T x86 power state %d = %s, in 0x%04x]\n",
|
||||
state, state_names[state], in_signals);
|
||||
|
||||
Reference in New Issue
Block a user