bd9995x: BD9995X_PMON_IOUT_ADC_READ_COUNT is a power of two

With the change, compiler won't use 64-bit division for
bd9995x_psys_charger_adc() function.

BRANCH=none
BUG=none
TEST=To replace "reg" variable and checking the return value
     if it is expected for both "bd9995x_psys_charger_adc()" and
     "bd9995x_amon_bmon_chg_adc()" functions.

Change-Id: Ifc461e5a54ce583ff59281ad13421c640ec9e21e
Signed-off-by: Dino Li <Dino.Li@ite.com.tw>
Reviewed-on: https://chromium-review.googlesource.com/485083
Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
This commit is contained in:
Dino Li
2017-05-09 12:48:18 +08:00
committed by chrome-bot
parent 9c48895225
commit 53b72194cd

View File

@@ -170,7 +170,7 @@ enum bd9995x_charge_port {
#define BD9995X_CMD_PMON_IOUT_CTRL_SET_PMON_GAIN_SET_04UAW 0x02
#define BD9995X_CMD_PMON_IOUT_CTRL_SET_PMON_GAIN_SET_02UAW 0x01
#define BD9995X_CMD_PMON_IOUT_CTRL_SET_PMON_GAIN_SET_01UAW 0x00
#define BD9995X_PMON_IOUT_ADC_READ_COUNT 100
#define BD9995X_PMON_IOUT_ADC_READ_COUNT 128
#define BD9995X_CMD_PMON_DACIN_VAL 0x26
#define BD9995X_CMD_IOUT_DACIN_VAL 0x27