From e9916b94cabdb2a56c5ccd71c836acb172fa014d Mon Sep 17 00:00:00 2001 From: Tom Wai-Hong Tam Date: Wed, 2 May 2018 13:35:18 -0700 Subject: [PATCH] cheza: Change ACOK_OD pin to EC input The ACOK_OD is a required signal of the charging state machine. EC can't always hold it low; however, it breaks the charging state. Make it back to EC input. There are some side-efforts, mentioned in the bug. BRANCH=none BUG=b:78035750 TEST=Plugged/unplugged AC when AP is on/off. TEST=Verified the power sequence still works. Change-Id: I039af9cdb86cfb509f2580e6f57d82309825dac1 Signed-off-by: Tom Wai-Hong Tam Reviewed-on: https://chromium-review.googlesource.com/1042620 Commit-Ready: Wai-Hong Tam Tested-by: Wai-Hong Tam Reviewed-by: Vincent Palatin --- board/cheza/gpio.inc | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/board/cheza/gpio.inc b/board/cheza/gpio.inc index 8f056073b7..8e3394d586 100644 --- a/board/cheza/gpio.inc +++ b/board/cheza/gpio.inc @@ -8,6 +8,11 @@ /* Declare symbolic names for all the GPIOs that we care about. * Note: Those with interrupt handlers must be declared first. */ +/* + * The ACOK_OD is also a PMIC power-on trigger, resulting some side-efforts. + * Check the bug (b/78035750) for details. The next hardware rev will fix it. + */ +GPIO_INT(AC_PRESENT, PIN(0, 0), GPIO_INT_BOTH | GPIO_PULL_UP, extpower_interrupt) /* ACOK_OD */ GPIO_INT(POWER_BUTTON_L, PIN(0, 1), GPIO_INT_BOTH, power_button_interrupt) /* EC_PWR_BTN_ODL */ GPIO_INT(VOLUME_DOWN_L, PIN(7, 0), GPIO_INT_BOTH | GPIO_PULL_UP, button_interrupt) /* EC_VOLDN_BTN_ODL */ GPIO_INT(VOLUME_UP_L, PIN(1, 1), GPIO_INT_BOTH | GPIO_PULL_UP, button_interrupt) /* EC_VOLUP_BTN_ODL */ @@ -17,11 +22,6 @@ GPIO_INT(AP_RST_REQ, PIN(C, 2), GPIO_INT_RISING | GPIO_PULL_DOWN, chipset /* AP_RST_L is used for PMIC and AP negotiation. Don't change its state. */ GPIO_INT(AP_RST_L, PIN(C, 1), GPIO_INT_BOTH, chipset_power_signal_interrupt) -/* - * Should always make it low, to prevent AP unexpected up. - * TODO(b/78035750): Remove it after hardware fix. - */ -GPIO(AC_PRESENT, PIN(0, 0), GPIO_OUT_LOW) /* ACOK_OD: PMIC power-on trigger PON_1 */ GPIO(EC_SELF_RST, PIN(E, 0), GPIO_OUT_LOW) /* Self-reset EC */ GPIO(SYS_RST_L, PIN(0, 2), GPIO_ODR_HIGH) /* PMIC reset trigger */ /* PS_HOLD is used for PMIC and AP negotiation. Don't change its state. */