diff options
author | Marco Chen <marcochen@chromium.org> | 2019-07-15 08:56:12 +0800 |
---|---|---|
committer | Martin Roth <martinroth@google.com> | 2019-07-16 16:33:12 +0000 |
commit | 9b0f93347249cf260fe7db0072131277b846cc1a (patch) | |
tree | f78aca71dfbdd8ea71dec96becb929e1e5912839 /src | |
parent | 8a6174d6e8925fed42b16b2d8db8c6403c1b3368 (diff) |
mb/google/octopus: add variant_smi_sleep
Allow variants to customize their own smi sleep flow.
BUG=b:137033609
BRANCH=octopus
TEST=built
Change-Id: I75db544d333a640848da9072878687c802c1c1a4
Signed-off-by: Marco Chen <marcochen@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/34340
Reviewed-by: Furquan Shaikh <furquan@google.com>
Reviewed-by: Karthik Ramasubramanian <kramasub@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'src')
-rw-r--r-- | src/mainboard/google/octopus/smihandler.c | 7 | ||||
-rw-r--r-- | src/mainboard/google/octopus/variants/baseboard/include/baseboard/variants.h | 3 |
2 files changed, 10 insertions, 0 deletions
diff --git a/src/mainboard/google/octopus/smihandler.c b/src/mainboard/google/octopus/smihandler.c index 27928eec0f..855c9825e8 100644 --- a/src/mainboard/google/octopus/smihandler.c +++ b/src/mainboard/google/octopus/smihandler.c @@ -39,6 +39,8 @@ void mainboard_smi_sleep(u8 slp_typ) pads = variant_sleep_gpio_table(&num, slp_typ); gpio_configure_pads(pads, num); + variant_smi_sleep(slp_typ); + chromeec_smi_sleep(slp_typ, MAINBOARD_EC_S3_WAKE_EVENTS, MAINBOARD_EC_S5_WAKE_EVENTS); } @@ -60,3 +62,8 @@ void elog_gsmi_cb_mainboard_log_wake_source(void) google_chromeec_log_events(MAINBOARD_EC_LOG_EVENTS | MAINBOARD_EC_S0IX_WAKE_EVENTS); } + +void __weak variant_smi_sleep(u8 slp_typ) +{ + /* Leave for the variant to implement if necessary. */ +} diff --git a/src/mainboard/google/octopus/variants/baseboard/include/baseboard/variants.h b/src/mainboard/google/octopus/variants/baseboard/include/baseboard/variants.h index 33a8f52527..140beb4649 100644 --- a/src/mainboard/google/octopus/variants/baseboard/include/baseboard/variants.h +++ b/src/mainboard/google/octopus/variants/baseboard/include/baseboard/variants.h @@ -51,4 +51,7 @@ void variant_update_devtree(struct device *dev); /* Get no touchscreen SKU ID. */ bool no_touchscreen_sku(uint32_t sku_id); +/* allow each variants to customize smi sleep flow. */ +void variant_smi_sleep(u8 slp_typ); + #endif /* BASEBOARD_VARIANTS_H */ |