aboutsummaryrefslogtreecommitdiff
path: root/drivers/regulator
diff options
context:
space:
mode:
authorVince Hsu <vinceh@nvidia.com>2013-11-28 19:10:42 +0800
committerMark Brown <broonie@linaro.org>2013-12-02 18:02:34 +0000
commit6389075eff7dc1e6db39203c968394486c13b3e2 (patch)
tree266e3cfae33c118dc11d0a5ad1b95830b0b2d52a /drivers/regulator
parent6ce4eac1f600b34f2f7f58f9cd8f0503d79e42ae (diff)
regulator: as3722: set the correct current limit
Simple fix to set the correct current limit for SD0/1/6. Signed-off-by: Vince Hsu <vinceh@nvidia.com> Signed-off-by: Mark Brown <broonie@linaro.org> Fixes: bc407334e9a6 (regulator: as3722: add regulator driver for AMS AS3722) Cc: stable@vger.kernel.org
Diffstat (limited to 'drivers/regulator')
-rw-r--r--drivers/regulator/as3722-regulator.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/regulator/as3722-regulator.c b/drivers/regulator/as3722-regulator.c
index 5917fe3dc98..b9f1d24c681 100644
--- a/drivers/regulator/as3722-regulator.c
+++ b/drivers/regulator/as3722-regulator.c
@@ -590,8 +590,8 @@ static int as3722_sd016_set_current_limit(struct regulator_dev *rdev,
default:
return -EINVAL;
}
+ ret <<= ffs(mask) - 1;
val = ret & mask;
- val <<= ffs(mask) - 1;
return as3722_update_bits(as3722, reg, mask, val);
}