diff options
author | Jan Dabros <jsd@semihalf.com> | 2021-02-16 12:28:03 +0100 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2021-02-17 14:47:51 +0000 |
commit | 142acc797b1dfc92f44c443103b361ad103a976f (patch) | |
tree | 6ae31641a97dc7b80b4213daba7cf2ca4ae55b02 /board/servo_v4p1 | |
parent | a6c856587d102780215243a640284a1c6e16746e (diff) | |
download | chrome-ec-142acc797b1dfc92f44c443103b361ad103a976f.tar.gz |
servo_v4p1: Fix BC1.2 detection pin assignment for REV2
REV1 of servo_v4p1 uses HOST_CHRG_DET as a GPIO which informs about
detecting extended-charge connection available (CDP or DCP). On REV2
BC1.2 detection chip was replaced with another part (PI3USB9201) and
this pin is asserted when detection is completed. STM needs to query I2C
interface of BC1.2 chip in order to get detailed info about available
power.
HOST_CHRG_DET on REV2 should be used as a trigger for reading PI3USB9201
detection results. This will be implemented in future.
BUG=b:144776402
BRANCH=main
TEST=build and flash servo_v4p1. After reboot, connect to console and
verify that there is no "BC1.2 charger unplugged" message visible in the
log.
Signed-off-by: Jan Dabros <jsd@semihalf.com>
Change-Id: I421a82d5496b6e5280f5023878c610d04fae9283
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2697071
Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
Reviewed-by: Aseda Aboagye <aaboagye@chromium.org>
Diffstat (limited to 'board/servo_v4p1')
-rw-r--r-- | board/servo_v4p1/ioexpanders.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/board/servo_v4p1/ioexpanders.c b/board/servo_v4p1/ioexpanders.c index 323db8dec3..c8190f86ab 100644 --- a/board/servo_v4p1/ioexpanders.c +++ b/board/servo_v4p1/ioexpanders.c @@ -179,7 +179,8 @@ static void ioexpanders_irq(void) ccprintf("off DAC1 to clear the fault\n"); } - if ((irqs & HOST_CHRG_DET) != bc12_charger) { + if (((irqs & HOST_CHRG_DET) != bc12_charger) && + (board_id_det() <= BOARD_ID_REV1)) { ccprintf("BC1.2 charger %s\n", (irqs & HOST_CHRG_DET) ? "plugged" : "unplugged"); bc12_charger = irqs & HOST_CHRG_DET; |