diff options
author | Furquan Shaikh <furquan@chromium.org> | 2017-10-30 19:41:59 -0700 |
---|---|---|
committer | chrome-bot <chrome-bot@chromium.org> | 2017-10-31 13:04:59 -0700 |
commit | d4d73eb806a9e480a9565f58f9637a9a669328de (patch) | |
tree | 403a94b87576f63713fd678a8c8ada8e2ebd69de /include | |
parent | 6f5ef069388fa5cdfb02aaf205d0a8e70f6b677a (diff) | |
download | chrome-ec-d4d73eb806a9e480a9565f58f9637a9a669328de.tar.gz |
power: Add default sleep event state HOST_SLEEP_EVENT_DEFAULT_RESET
Instead of using HOST_SLEEP_EVENT_S0IX_RESUME as a reset state to
reinitialize S0ix flag, add a new default state
HOST_SLEEP_EVENT_DEFAULT_RESET. This also allows different parts of
the code to take correct action depending upon the state that is
currently triggered.
BUG=None
BRANCH=None
TEST=Verified that SLP_S0# interrupt doesn't get asserted during
runtime S0ix.
Change-Id: Id6fc8f3b015561d2899a9d39796b77a11a57e758
Signed-off-by: Furquan Shaikh <furquan@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/745901
Reviewed-by: Aaron Durbin <adurbin@chromium.org>
Diffstat (limited to 'include')
-rw-r--r-- | include/power.h | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/include/power.h b/include/power.h index 20b2ee6cf6..271b8add69 100644 --- a/include/power.h +++ b/include/power.h @@ -200,13 +200,21 @@ void power_chipset_handle_host_sleep_event(enum host_sleep_event state); */ void power_board_handle_host_sleep_event(enum host_sleep_event state); +/* + * This is the default state of host sleep event. Calls to + * power_reset_host_sleep_state will set host sleep event to this + * value. EC components listening to host sleep event updates can check for this + * special value to know if the state was reset. + */ +#define HOST_SLEEP_EVENT_DEFAULT_RESET 0 + #ifdef CONFIG_POWER_S0IX /** * Reset the sleep state reported by the host. * * @param sleep_event Reset sleep state. */ -void power_reset_host_sleep_state(enum host_sleep_event sleep_event); +void power_reset_host_sleep_state(void); #endif /* CONFIG_POWER_S0IX */ #endif /* CONFIG_POWER_TRACK_HOST_SLEEP_STATE */ |