diff options
author | Aseda Aboagye <aaboagye@google.com> | 2020-04-03 16:11:58 -0700 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2020-04-15 02:11:15 +0000 |
commit | 2daf48c4146649729e6a369608a52168e0849764 (patch) | |
tree | 63b3a0144984e65888280c71d7bd0db181996040 /driver/charger/isl923x.h | |
parent | be61a53ffa746143eaf3817bff4bf66ae42babf6 (diff) | |
download | chrome-ec-2daf48c4146649729e6a369608a52168e0849764.tar.gz |
raa489000: Fix get_input_current()
The RAA489000 has an ADC register for retrieving the instantaneous
input current. This commit fixes a bug where we were simply returning
our input current limit instead of what the actual input current was.
BUG=b:148980034
BRANCH=None
TEST=Build and flash waddledoo, verify that the instantaneous input
current is returned.
Signed-off-by: Aseda Aboagye <aaboagye@google.com>
Change-Id: I392ba8a4180fda5fb03e98a08f3c5bbfa51d6186
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2135962
Commit-Queue: Aseda Aboagye <aaboagye@chromium.org>
Tested-by: Aseda Aboagye <aaboagye@chromium.org>
Reviewed-by: Diana Z <dzigterman@chromium.org>
Diffstat (limited to 'driver/charger/isl923x.h')
-rw-r--r-- | driver/charger/isl923x.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/driver/charger/isl923x.h b/driver/charger/isl923x.h index ff57dba1e8..3ff0de9d69 100644 --- a/driver/charger/isl923x.h +++ b/driver/charger/isl923x.h @@ -264,6 +264,8 @@ #define ISL9237_INFO_PSTATE_MASK 3 /* ADC registers */ +#define RAA489000_REG_ADC_INPUT_CURRENT 0x83 +#define RAA489000_REG_ADC_VSYS 0x86 #define RAA489000_REG_ADC_VBUS 0x88 enum isl9237_power_stage { |