diff options
author | Daisuke Nojiri <dnojiri@chromium.org> | 2021-02-01 10:06:15 -0800 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2021-02-12 03:00:46 +0000 |
commit | eb0d724fdf3e7ce15ac2b7c13403aefc355f718f (patch) | |
tree | 86575374d6ed7e6b8c3db10bd9ffdfd3091af827 /board/coachz | |
parent | 6776d3250648aab3c685c0a4de372094aba7d742 (diff) | |
download | chrome-ec-eb0d724fdf3e7ce15ac2b7c13403aefc355f718f.tar.gz |
pchg: Notify host of full charge
Currently, full charge status is implied by capacity = 100 and
PCHG_STATE_DETECTED (i.e. state='not charging'). If the charger
stops charging before 100% (for battery health control), this
condition doesn't work.
This patch makes PCHG send PCHG_STATE_FULL explicitly when it sees
the soc goes above the threshold in PCHG_STATE_DETECTED.
BUG=b:179390065,b:173235954
BRANCH=trogdor
TEST=CoachZ. Charge till 96% and verify PCHG0/state becomes 'Full'.
Signed-off-by: Daisuke Nojiri <dnojiri@chromium.org>
Change-Id: I634f96992cdc7ef44b5e43544603cc5cc9b3a62d
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2691366
Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
Diffstat (limited to 'board/coachz')
-rw-r--r-- | board/coachz/board.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/board/coachz/board.c b/board/coachz/board.c index 6ebf0c4ab3..a6673b401b 100644 --- a/board/coachz/board.c +++ b/board/coachz/board.c @@ -58,6 +58,7 @@ struct pchg pchgs[] = { .drv = &ctn730_drv, .i2c_port = I2C_PORT_WLC, .irq_pin = GPIO_WLC_IRQ_CONN, + .full_percent = 96, }, .events = QUEUE_NULL(PCHG_EVENT_QUEUE_SIZE, enum pchg_event), }, |