summaryrefslogtreecommitdiff
path: root/drivers/regulator
diff options
context:
space:
mode:
authorMark Brown <broonie@linaro.org>2014-07-04 18:02:06 (GMT)
committerMark Brown <broonie@linaro.org>2014-07-04 18:02:06 (GMT)
commit448b55c2a360a2d531d9e4b78bc87ecc2d235782 (patch)
tree2b19ea7f3df22d56cdab3bba96266e0ca6bd12cd /drivers/regulator
parent7171511eaec5bf23fb06078f59784a3a0626b38f (diff)
parent342d669c1ee421323f552a62729d3a3d0065093c (diff)
downloadlinux-448b55c2a360a2d531d9e4b78bc87ecc2d235782.tar.xz
Merge tag 'mfd-extcon-regulator-v3.17' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd into regulator-s2mpu02
Immutable branch between MFD, Extcon and Regulator due for v3.17
Diffstat (limited to 'drivers/regulator')
-rw-r--r--drivers/regulator/max77693.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/regulator/max77693.c b/drivers/regulator/max77693.c
index 653a58b..c67ff05 100644
--- a/drivers/regulator/max77693.c
+++ b/drivers/regulator/max77693.c
@@ -31,6 +31,7 @@
#include <linux/mfd/max77693.h>
#include <linux/mfd/max77693-private.h>
#include <linux/regulator/of_regulator.h>
+#include <linux/regmap.h>
#define CHGIN_ILIM_STEP_20mA 20000
@@ -39,9 +40,9 @@
static int max77693_chg_is_enabled(struct regulator_dev *rdev)
{
int ret;
- u8 val;
+ unsigned int val;
- ret = max77693_read_reg(rdev->regmap, rdev->desc->enable_reg, &val);
+ ret = regmap_read(rdev->regmap, rdev->desc->enable_reg, &val);
if (ret)
return ret;
@@ -57,12 +58,11 @@ static int max77693_chg_get_current_limit(struct regulator_dev *rdev)
{
unsigned int chg_min_uA = rdev->constraints->min_uA;
unsigned int chg_max_uA = rdev->constraints->max_uA;
- u8 reg, sel;
+ unsigned int reg, sel;
unsigned int val;
int ret;
- ret = max77693_read_reg(rdev->regmap,
- MAX77693_CHG_REG_CHG_CNFG_09, &reg);
+ ret = regmap_read(rdev->regmap, MAX77693_CHG_REG_CHG_CNFG_09, &reg);
if (ret < 0)
return ret;
@@ -96,7 +96,7 @@ static int max77693_chg_set_current_limit(struct regulator_dev *rdev,
/* the first four codes for charger current are all 60mA */
sel += 3;
- return max77693_write_reg(rdev->regmap,
+ return regmap_write(rdev->regmap,
MAX77693_CHG_REG_CHG_CNFG_09, sel);
}
/* end of CHARGER regulator ops */