From 6183b29559107650cb38f905e069a93ff9da1d7d Mon Sep 17 00:00:00 2001 From: Keerthy Date: Wed, 24 May 2017 10:19:27 +0530 Subject: power: pmic: tps65218: Fix tps65218_voltage_update function Currently while setting the vsel value for dcdc1 and dcdc2 the driver is wrongly masking the entire 8 bits in the process clearing PFM (bit7) field as well. Hence describe an appropriate mask for vsel field and modify only those bits in the vsel mask. Source: http://www.ti.com/lit/ds/symlink/tps65218.pdf Signed-off-by: Keerthy Fixes: 86db550b38 ("power: Add support for the TPS65218 PMIC") Reviewed-by: Jaehoon Chung --- drivers/power/pmic/pmic_tps65218.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers/power') diff --git a/drivers/power/pmic/pmic_tps65218.c b/drivers/power/pmic/pmic_tps65218.c index f32fa40863..c5e768ae4b 100644 --- a/drivers/power/pmic/pmic_tps65218.c +++ b/drivers/power/pmic/pmic_tps65218.c @@ -101,7 +101,7 @@ int tps65218_voltage_update(uchar dc_cntrl_reg, uchar volt_sel) /* set voltage level */ if (tps65218_reg_write(TPS65218_PROT_LEVEL_2, dc_cntrl_reg, volt_sel, - TPS65218_MASK_ALL_BITS)) + TPS65218_DCDC_VSEL_MASK)) return 1; /* set GO bit to initiate voltage transition */ -- cgit v1.2.1