diff --git a/board/ryu/board.h b/board/ryu/board.h index 4d7d28c0a5..eb982ed44f 100644 --- a/board/ryu/board.h +++ b/board/ryu/board.h @@ -82,6 +82,7 @@ #define CONFIG_POWER_COMMON #define CONFIG_POWER_BUTTON #define CONFIG_POWER_BUTTON_ACTIVE_STATE 1 +#define CONFIG_POWER_IGNORE_LID_OPEN /* I2C ports configuration */ #define I2C_PORT_MASTER 0 diff --git a/include/config.h b/include/config.h index 46aed17057..208a19957c 100644 --- a/include/config.h +++ b/include/config.h @@ -1059,6 +1059,9 @@ /* Compile common code for AP power state machine */ #undef CONFIG_POWER_COMMON +/* Disable the power-on transition when the lid is opened */ +#undef CONFIG_POWER_IGNORE_LID_OPEN + /* Support stopping in S5 on shutdown */ #undef CONFIG_POWER_SHUTDOWN_PAUSE_IN_S5 diff --git a/power/tegra.c b/power/tegra.c index 5efd41e61d..75c00327fb 100644 --- a/power/tegra.c +++ b/power/tegra.c @@ -231,7 +231,7 @@ static int check_for_power_off_event(void) return 0; } - +#ifndef CONFIG_POWER_IGNORE_LID_OPEN static void tegra_lid_event(void) { /* Power task only cares about lid-open events */ @@ -242,6 +242,7 @@ static void tegra_lid_event(void) task_wake(TASK_ID_CHIPSET); } DECLARE_HOOK(HOOK_LID_CHANGE, tegra_lid_event, HOOK_PRIO_DEFAULT); +#endif /* !CONFIG_POWER_IGNORE_LID_OPEN */ enum power_state power_chipset_init(void) {