diff options
author | Furquan Shaikh <furquan@google.com> | 2018-04-30 19:10:49 -0700 |
---|---|---|
committer | chrome-bot <chrome-bot@chromium.org> | 2018-05-02 22:20:50 -0700 |
commit | 24c077476d8263d9257b5840d4e502d5692c8b73 (patch) | |
tree | c29013f6df987ba487078dab32719a1794968dd1 /board/yorp/board.c | |
parent | c44f56739a671b188081979d159638f107b281d9 (diff) | |
download | chrome-ec-24c077476d8263d9257b5840d4e502d5692c8b73.tar.gz |
yorp: Control backlight based on chipset transitions
This change enables/disables backlight based on the chipset state
transition.
BUG=b:78897667
BRANCH=None
TEST=None
Change-Id: I4da331cb94f7a304a76fce93b73c38016f5b0f4d
Signed-off-by: Furquan Shaikh <furquan@google.com>
Reviewed-on: https://chromium-review.googlesource.com/1036798
Commit-Ready: Furquan Shaikh <furquan@chromium.org>
Tested-by: Furquan Shaikh <furquan@chromium.org>
Reviewed-by: Aaron Durbin <adurbin@chromium.org>
Reviewed-by: Jett Rink <jettrink@chromium.org>
Reviewed-by: Justin TerAvest <teravest@chromium.org>
Diffstat (limited to 'board/yorp/board.c')
-rw-r--r-- | board/yorp/board.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/board/yorp/board.c b/board/yorp/board.c index 133e0da19f..d573571aff 100644 --- a/board/yorp/board.c +++ b/board/yorp/board.c @@ -213,6 +213,12 @@ static void board_chipset_resume(void) { /* Enable Trackpad Power when chipset is in S0 */ gpio_set_level(GPIO_EN_P3300_TRACKPAD_ODL, 0); + + /* + * GPIO_ENABLE_BACKLIGHT is AND'ed with SOC_EDP_BKLTEN from the SoC and + * LID_OPEN connection in hardware. + */ + gpio_set_level(GPIO_ENABLE_BACKLIGHT, 1); } DECLARE_HOOK(HOOK_CHIPSET_RESUME, board_chipset_resume, HOOK_PRIO_DEFAULT); @@ -221,6 +227,12 @@ static void board_chipset_suspend(void) { /* Disable Trackpad Power when chipset transitions to sleep state */ gpio_set_level(GPIO_EN_P3300_TRACKPAD_ODL, 1); + + /* + * GPIO_ENABLE_BACKLIGHT is AND'ed with SOC_EDP_BKLTEN from the SoC and + * LID_OPEN connection in hardware. + */ + gpio_set_level(GPIO_ENABLE_BACKLIGHT, 0); } DECLARE_HOOK(HOOK_CHIPSET_SUSPEND, board_chipset_suspend, HOOK_PRIO_DEFAULT); |