diff options
author | Yilun Lin <yllin@chromium.org> | 2019-11-22 15:59:47 +0800 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2019-12-17 08:29:18 +0000 |
commit | a2804b7cc86962a28ede119cda23ea1d13d49922 (patch) | |
tree | 61540774ee57638b315fcb864dd8e825388da4e4 /driver/charger/rt946x.c | |
parent | c0fac86829c4bf0345c568584f3ab1a981866595 (diff) | |
download | chrome-ec-a2804b7cc86962a28ede119cda23ea1d13d49922.tar.gz |
baseboard/kukui: request high voltage PDO if battery current drops
Request a higher voltage PDO (> 5V), when we requested 5V PDO and
seeing a battery charging current drop.
Ideally, when CONFIG_USB_PD_PREFER_MV enabled, the system will
request 5V/3A PDO when system desired power under 15W. However,
mt6370 has bad bulking efficiency and stops itself from sinking
more power (only sink under around 11W). The bad bulking efficiency
is getting worse if the gap between VBUS and VBAT getting closer.
To overcome this, we need to watch the battery charging current when
we switch to 5V. If we see a current drop after that, this means
we are suffering the bulking issue, and slows down the charging.
In this time, we will request a high voltage PDO by setting
PD_PREFER_MV above 5000. After request a new PDO, It will attempts to
switch to 5V in a few seconds or minutes, and see if we are still
suffering the issue.
TEST=1. When there is a battery current drop while switching from 9V to
5V, PD can switch back to 9V.
2. When no battery current drop while switching from 9V to 5V, PD
won't switch back
3. ensure that pd_task can request 9V when board_get_desired_power()
is between 15W and 11W.
BUG=b:143318064 b:141903096 b:144073892
BRANCH=kukui
Change-Id: I6c2c0c948c417b81e70ca6c6d360b89b941f3888
Signed-off-by: Yilun Lin <yllin@chromium.org>
Signed-off-by: Eric Yilun Lin <yllin@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1899659
Reviewed-by: Ting Shen <phoenixshen@chromium.org>
Diffstat (limited to 'driver/charger/rt946x.c')
0 files changed, 0 insertions, 0 deletions