regulator: tps65910: Simplify setting enable_mask for regulators

BBCH_BBCHEN_MASK is equivalent to TPS65910_SUPPLY_STATE_ENABLED.
So all regulators have the same enable_mask setting.

BBCH_BBCHEN_MASK and BBCH_BBCHEN_SHIFT are not used now, remove them.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Signed-off-by: Mark Brown <broonie@linaro.org>
This commit is contained in:
Axel Lin 2013-12-29 17:00:20 +08:00 committed by Mark Brown
parent 03746dcbde
commit b8903eb983
2 changed files with 1 additions and 17 deletions

View File

@ -1207,21 +1207,7 @@ static int tps65910_probe(struct platform_device *pdev)
pmic->desc[i].type = REGULATOR_VOLTAGE; pmic->desc[i].type = REGULATOR_VOLTAGE;
pmic->desc[i].owner = THIS_MODULE; pmic->desc[i].owner = THIS_MODULE;
pmic->desc[i].enable_reg = pmic->get_ctrl_reg(i); pmic->desc[i].enable_reg = pmic->get_ctrl_reg(i);
pmic->desc[i].enable_mask = TPS65910_SUPPLY_STATE_ENABLED;
switch (i) {
case TPS65910_REG_VBB:
if (tps65910_chip_id(tps65910) == TPS65910)
pmic->desc[i].enable_mask = BBCH_BBCHEN_MASK;
else
pmic->desc[i].enable_mask =
TPS65910_SUPPLY_STATE_ENABLED;
break;
default:
pmic->desc[i].enable_mask =
TPS65910_SUPPLY_STATE_ENABLED;
break;
}
config.dev = tps65910->dev; config.dev = tps65910->dev;
config.init_data = reg_data; config.init_data = reg_data;

View File

@ -358,8 +358,6 @@
/*Register BBCH (0x80) register.RegisterDescription */ /*Register BBCH (0x80) register.RegisterDescription */
#define BBCH_BBSEL_MASK 0x06 #define BBCH_BBSEL_MASK 0x06
#define BBCH_BBSEL_SHIFT 1 #define BBCH_BBSEL_SHIFT 1
#define BBCH_BBCHEN_MASK 0x01
#define BBCH_BBCHEN_SHIFT 0
/*Register DCDCCTRL (0x80) register.RegisterDescription */ /*Register DCDCCTRL (0x80) register.RegisterDescription */