From aec855ac89ec034ba904806acac6ade729993426 Mon Sep 17 00:00:00 2001 From: Lin Huang Date: Fri, 22 Dec 2017 10:57:59 +0800 Subject: scarlet: shutdown PP900_S0 power rail when S3 we need to shutdown PP900_S0 power rail when S3 to save power consumption, let's do it. BUG=b:62644399 BRANCH=none TEST=run suspend_stress_test, it pass 1000 cycles CQ-DEPEND=CL:890228 Change-Id: I366effe9d2a99cb608069dd5d599171d32a9b4ce Signed-off-by: Lin Huang Reviewed-on: https://chromium-review.googlesource.com/841902 Commit-Ready: Brian Norris Tested-by: Derek Basehore Tested-by: Brian Norris Reviewed-by: Derek Basehore Reviewed-by: Brian Norris --- power/rk3399.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/power/rk3399.c b/power/rk3399.c index fb7a437ef1..51211d0c69 100644 --- a/power/rk3399.c +++ b/power/rk3399.c @@ -94,7 +94,6 @@ BUILD_ASSERT(GPIO_COUNT < 256); #if CONFIG_CHIPSET_POWER_SEQ_VERSION == 2 static const struct power_seq_op s5s3_power_seq[] = { - { GPIO_PP900_S0_EN, 1, 2 }, { GPIO_PP900_S3_EN, 1, 2 }, { GPIO_PP3300_S3_EN, 1, 2 }, { GPIO_PP1800_S3_EN, 1, 2 }, @@ -143,6 +142,7 @@ static const struct power_seq_op s3s0_power_seq[] = { #ifdef S3_USB_WAKE /* Sigs that may already be on in S3, if we need to wake-on-USB */ static const struct power_seq_op s3s0_usb_wake_power_seq[] = { + { GPIO_PP900_S0_EN, 1, 2 }, { GPIO_PP1800_USB_EN, 1, 2 }, { GPIO_PP3300_S0_EN, 1, 2 }, }; @@ -170,6 +170,7 @@ static const struct power_seq_op s0s3_usb_wake_power_seq[] = { { GPIO_PP3300_S0_EN, 0, 20 }, { GPIO_PP1800_S0_EN, 0, 1 }, { GPIO_PP1800_USB_EN, 0, 1 }, + { GPIO_PP900_S0_EN, 0, 0 }, }; #endif @@ -181,7 +182,6 @@ static const struct power_seq_op s3s5_power_seq[] = { { GPIO_PP1800_S3_EN, 0, 2 }, { GPIO_PP3300_S3_EN, 0, 2 }, { GPIO_PP900_S3_EN, 0, 0 }, - { GPIO_PP900_S0_EN, 0, 0 }, }; #else static const struct power_seq_op s3s5_power_seq[] = { -- cgit v1.2.1