help
This driver supports ISL6271A voltage regulator chip.
+++++config REGULATOR_LM363X
+++++ tristate "TI LM363X voltage regulators"
+++++ depends on MFD_TI_LMU
+++++ help
+++++ This driver supports LM3631 and LM3632 voltage regulators for
+++++ the LCD bias.
+++++ One boost output voltage is configurable and always on.
+++++ Other LDOs are used for the display module.
+++++
config REGULATOR_LP3971
tristate "National Semiconductors LP3971 PMIC regulator driver"
depends on I2C
config REGULATOR_MT6311
tristate "MediaTek MT6311 PMIC"
depends on I2C
+++++ select REGMAP_I2C
help
Say y here to select this option to enable the power regulator of
MediaTek MT6311 PMIC.
Say y here to support the regulators found on the Freescale
PFUZE100/PFUZE200 PMIC.
+++++ config REGULATOR_PV88060
+++++ tristate "Powerventure Semiconductor PV88060 regulator"
+++++ depends on I2C
+++++ select REGMAP_I2C
+++++ help
+++++ Say y here to support the voltage regulators and convertors
+++++ PV88060
+++++
config REGULATOR_PWM
tristate "PWM voltage regulator"
depends on PWM
obj-$(CONFIG_REGULATOR_HI6421) += hi6421-regulator.o
obj-$(CONFIG_REGULATOR_ISL6271A) += isl6271a-regulator.o
obj-$(CONFIG_REGULATOR_ISL9305) += isl9305.o
+++++obj-$(CONFIG_REGULATOR_LM363X) += lm363x-regulator.o
obj-$(CONFIG_REGULATOR_LP3971) += lp3971.o
obj-$(CONFIG_REGULATOR_LP3972) += lp3972.o
obj-$(CONFIG_REGULATOR_LP872X) += lp872x.o
obj-$(CONFIG_REGULATOR_QCOM_SPMI) += qcom_spmi-regulator.o
obj-$(CONFIG_REGULATOR_PALMAS) += palmas-regulator.o
obj-$(CONFIG_REGULATOR_PFUZE100) += pfuze100-regulator.o
+++++ obj-$(CONFIG_REGULATOR_PV88060) += pv88060-regulator.o
obj-$(CONFIG_REGULATOR_PWM) += pwm-regulator.o
obj-$(CONFIG_REGULATOR_TPS51632) += tps51632-regulator.o
obj-$(CONFIG_REGULATOR_PBIAS) += pbias-regulator.o
return has_full_constraints || of_have_populated_dt();
}
+++++static inline struct regulator_dev *rdev_get_supply(struct regulator_dev *rdev)
+++++{
+++++ if (rdev && rdev->supply)
+++++ return rdev->supply->rdev;
+++++
+++++ return NULL;
+++++}
+++++
/**
* regulator_lock_supply - lock a regulator and its supplies
* @rdev: regulator source
*/
static void regulator_lock_supply(struct regulator_dev *rdev)
{
----- struct regulator *supply;
----- int i = 0;
-----
----- while (1) {
----- mutex_lock_nested(&rdev->mutex, i++);
----- supply = rdev->supply;
-----
----- if (!rdev->supply)
----- return;
+++++ int i;
----- rdev = supply->rdev;
----- }
+++++ for (i = 0; rdev; rdev = rdev_get_supply(rdev), i++)
+++++ mutex_lock_nested(&rdev->mutex, i);
}
/**
int regulator_disable_deferred(struct regulator *regulator, int ms)
{
struct regulator_dev *rdev = regulator->rdev;
----- int ret;
if (regulator->always_on)
return 0;
rdev->deferred_disables++;
mutex_unlock(&rdev->mutex);
----- ret = queue_delayed_work(system_power_efficient_wq,
----- &rdev->disable_work,
----- msecs_to_jiffies(ms));
----- if (ret < 0)
----- return ret;
----- else
----- return 0;
+++++ queue_delayed_work(system_power_efficient_wq, &rdev->disable_work,
+++++ msecs_to_jiffies(ms));
+++++ return 0;
}
EXPORT_SYMBOL_GPL(regulator_disable_deferred);
consumers[i].consumer = NULL;
for (i = 0; i < num_consumers; i++) {
--- -- consumers[i].consumer = regulator_get(dev,
--- -- consumers[i].supply);
+++ ++ consumers[i].consumer = _regulator_get(dev,
+++ ++ consumers[i].supply,
+++ ++ false,
+++ ++ !consumers[i].optional);
if (IS_ERR(consumers[i].consumer)) {
ret = PTR_ERR(consumers[i].consumer);
dev_err(dev, "Failed to get supply '%s': %d\n",
struct attribute *attr, int idx)
{
struct device *dev = kobj_to_dev(kobj);
----- struct regulator_dev *rdev = container_of(dev, struct regulator_dev, dev);
+++++ struct regulator_dev *rdev = dev_to_rdev(dev);
const struct regulator_ops *ops = rdev->desc->ops;
umode_t mode = attr->mode;