diff options
author | Wai-Hong Tam <waihong@google.com> | 2020-01-23 16:15:21 -0800 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2020-02-01 01:10:58 +0000 |
commit | 533a9c70dc94ddf4c98d7bf7ad2faf980acf9ec2 (patch) | |
tree | 534618a16c4f72a909dfc4c53f362ec9576aac40 | |
parent | 949f80604eec3c4f6d4a6fcfb2970461b221f00e (diff) | |
download | chrome-ec-533a9c70dc94ddf4c98d7bf7ad2faf980acf9ec2.tar.gz |
Trogdor: Remove the IN_POWER_GOOD power-on trigger in S5/G3
This trigger is not necessary for production use case. Remove it.
BRANCH=None
BUG=b:147818450
TEST=sysjump to RW, checked that AP keeps the same state.
TEST=Tested reboot ap-off, checked that AP off from reset.
TEST=Tested commands: apreset, power off, power on, apshutdown.
Change-Id: Ia7ebd9d56ed70ec902224bff7d6308bc37e7fa1e
Signed-off-by: Wai-Hong Tam <waihong@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2018040
Commit-Queue: Alexandru M Stan <amstan@chromium.org>
Tested-by: Alexandru M Stan <amstan@chromium.org>
Reviewed-by: Alexandru M Stan <amstan@chromium.org>
-rw-r--r-- | power/sc7180.c | 25 |
1 files changed, 0 insertions, 25 deletions
diff --git a/power/sc7180.c b/power/sc7180.c index 50e8485609..fafe244abd 100644 --- a/power/sc7180.c +++ b/power/sc7180.c @@ -133,7 +133,6 @@ enum power_off_event_t { */ enum power_on_event_t { POWER_ON_CANCEL, - POWER_ON_BY_IN_POWER_GOOD, POWER_ON_BY_AUTO_POWER_ON, POWER_ON_BY_LID_OPEN, POWER_ON_BY_POWER_BUTTON_PRESSED, @@ -549,11 +548,6 @@ static void power_on(void) */ static uint8_t check_for_power_on_event(void) { - int ap_off_flag; - - ap_off_flag = system_get_reset_flags() & EC_RESET_FLAG_AP_OFF; - system_clear_reset_flags(EC_RESET_FLAG_AP_OFF); - if (power_request == POWER_REQ_ON) { power_request = POWER_REQ_NONE; return POWER_ON_BY_POWER_REQ_ON; @@ -564,25 +558,6 @@ static uint8_t check_for_power_on_event(void) return POWER_ON_BY_POWER_REQ_RESET; } - /* check if system is already ON */ - if (power_get_signals() & IN_POWER_GOOD) { - if (ap_off_flag) { - CPRINTS("system is on, but EC_RESET_FLAG_AP_OFF is on"); - return POWER_ON_CANCEL; - } - CPRINTS("system is on, thus clear auto_power_on"); - /* no need to arrange another power on */ - auto_power_on = 0; - return POWER_ON_BY_IN_POWER_GOOD; - } - if (ap_off_flag) { - CPRINTS("EC_RESET_FLAG_AP_OFF is on"); - power_off(); - return POWER_ON_CANCEL; - } - - CPRINTS("POWER_GOOD is not asserted"); - /* power on requested at EC startup for recovery */ if (auto_power_on) { auto_power_on = 0; |