summaryrefslogtreecommitdiff
path: root/board/waddledee
diff options
context:
space:
mode:
authorDiana Z <dzigterman@chromium.org>2020-04-09 17:02:35 -0600
committerCommit Bot <commit-bot@chromium.org>2020-04-10 07:56:46 +0000
commit207082eb3ca62116e55c3a15d04b532db70026c3 (patch)
tree6f8aca547dad60b33ed6078e4504f657da7d872c /board/waddledee
parent382d22af0ffafba034f254276c5a6481ccbba1de (diff)
downloadchrome-ec-207082eb3ca62116e55c3a15d04b532db70026c3.tar.gz
SM5803: Add open drain parameter to GPIO setup
Explicitly set GPIO0 to be open drain or not, depending on the application needed. BRANCH=None BUG=b:153398237 TEST=on waddledee, redriver now inits and responds correctly Signed-off-by: Diana Z <dzigterman@chromium.org> Change-Id: Iaf6c66841a618ae5a522ad7f817dac3a5e0c755c Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2145074 Reviewed-by: Aseda Aboagye <aaboagye@chromium.org>
Diffstat (limited to 'board/waddledee')
-rw-r--r--board/waddledee/board.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/board/waddledee/board.c b/board/waddledee/board.c
index 858a00c98c..0abcb200c1 100644
--- a/board/waddledee/board.c
+++ b/board/waddledee/board.c
@@ -91,12 +91,12 @@ void board_init(void)
gpio_enable_interrupt(GPIO_USB_C1_INT_ODL);
gpio_enable_interrupt(GPIO_USB_C0_CCSBU_OVP_ODL);
- /* Charger on the MB will be outputting PROCHOT and OD CHG_DET */
- sm5803_configure_gpio0(CHARGER_PRIMARY, GPIO0_MODE_PROCHOT);
+ /* Charger on the MB will be outputting PROCHOT_ODL and OD CHG_DET */
+ sm5803_configure_gpio0(CHARGER_PRIMARY, GPIO0_MODE_PROCHOT, 1);
sm5803_configure_chg_det_od(CHARGER_PRIMARY, 1);
- /* Charger on the sub-board will be a GPIO */
- sm5803_configure_gpio0(CHARGER_SECONDARY, GPIO0_MODE_OUTPUT);
+ /* Charger on the sub-board will be a push-pull GPIO */
+ sm5803_configure_gpio0(CHARGER_SECONDARY, GPIO0_MODE_OUTPUT, 0);
/* Turn on 5V if the system is on, otherwise turn it off */
on = chipset_in_state(CHIPSET_STATE_ON | CHIPSET_STATE_ANY_SUSPEND);