diff options
-rw-r--r-- | board/kunimitsu/board.h | 4 | ||||
-rw-r--r-- | include/config.h | 3 | ||||
-rw-r--r-- | power/skylake.c | 22 |
3 files changed, 21 insertions, 8 deletions
diff --git a/board/kunimitsu/board.h b/board/kunimitsu/board.h index 0aa33dd82f..013eb233d7 100644 --- a/board/kunimitsu/board.h +++ b/board/kunimitsu/board.h @@ -113,8 +113,8 @@ #undef CONFIG_CONSOLE_HISTORY #undef CONFIG_PECI -/* Enable sleep mode in G3 */ -#define CONFIG_G3_SLEEP +/* Enable Pseudo G3 */ +#define CONFIG_LOW_POWER_PSEUDO_G3 #ifndef __ASSEMBLER__ diff --git a/include/config.h b/include/config.h index b8d97d79c5..7172f54697 100644 --- a/include/config.h +++ b/include/config.h @@ -1146,9 +1146,6 @@ */ #undef CONFIG_LOW_POWER_S0 -/* Support G3 sleep mode */ -#undef CONFIG_G3_SLEEP - /* Support LPC interface */ #undef CONFIG_LPC diff --git a/power/skylake.c b/power/skylake.c index 343d230297..a766901e67 100644 --- a/power/skylake.c +++ b/power/skylake.c @@ -279,9 +279,6 @@ static enum power_state _power_handle_state(enum power_state state) return POWER_S5; case POWER_S5G3: -#ifdef CONFIG_G3_SLEEP - gpio_set_level(GPIO_G3_SLEEP_EN, 1); -#endif chipset_force_g3(); return POWER_G3; @@ -340,3 +337,22 @@ enum power_state power_handle_state(enum power_state state) return new_state; } + +#ifdef CONFIG_LOW_POWER_PSEUDO_G3 +void enter_pseudo_g3(void) +{ + CPRINTS("Enter Psuedo G3"); + + /* + * Clean up the UART buffer and prevent any unwanted garbage characters + * before power off and also ensure above debug message is printed. + */ + cflush(); + + gpio_set_level(GPIO_G3_SLEEP_EN, 1); + + /* Power to EC should shut down now */ + while (1) + ; +} +#endif |