From 3824526de4f201d9d85bdd41ad2343a0e3d2ef37 Mon Sep 17 00:00:00 2001 From: Subbaraman Narayanamurthy Date: Wed, 25 Jan 2017 14:01:10 -0800 Subject: regulator: qpnp-labibb: fix incorrect configuration of SWIRE control Instead of using the value read from IBB_ENABLE_CTL register to determine whether SWIRE control is already enabled by bootloader, wrong value is used. Fix it. Change-Id: I80ddf60a3a8010a749a001f10ba82e6560ecdfd2 Signed-off-by: Subbaraman Narayanamurthy --- drivers/regulator/qpnp-labibb-regulator.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/regulator/qpnp-labibb-regulator.c b/drivers/regulator/qpnp-labibb-regulator.c index 67b97256da1f..7586570ef75d 100644 --- a/drivers/regulator/qpnp-labibb-regulator.c +++ b/drivers/regulator/qpnp-labibb-regulator.c @@ -3407,7 +3407,8 @@ static int register_qpnp_ibb_regulator(struct qpnp_labibb *labibb, * before by the bootloader. */ if (labibb->pmic_rev_id->pmic_subtype == PMI8998_SUBTYPE) - labibb->swire_control = val & IBB_ENABLE_CTL_SWIRE_RDY; + labibb->swire_control = ibb_enable_ctl & + IBB_ENABLE_CTL_SWIRE_RDY; if (ibb_enable_ctl & (IBB_ENABLE_CTL_SWIRE_RDY | IBB_ENABLE_CTL_MODULE_EN)) { -- cgit v1.2.3