summaryrefslogtreecommitdiffstats
path: root/drivers/regulator (follow)
Commit message (Collapse)AuthorAgeFilesLines
* regulator: wm8350: Don't specify consumer supplies with struct deviceMark Brown2012-02-021-2/+2
| | | | | | Very, very deprecated. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* regulator: tps65910: Sleep control through external inputsLaxman Dewangan2012-01-301-0/+206
| | | | | | | | | | | | | Add support for sleep controls of different regulator through external inputs EN1, EN2 or EN3. Each regulator's output will be active when its external input is high and turns to OFF/Low power mode when its external input is low. The configuration parameters for sleep control is provided through board specific platform data. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* regulator: mc13xxx-regulator-core: Fix the build when driver is selected as ↵Fabio Estevam2012-01-241-0/+2
| | | | | | | | | | | | | module Fix the following build error when mc138xxx driver is built as module: ERROR: "mc13xxx_parse_regulators_dt" [drivers/regulator/mc13892-regulator.ko] undefined! ERROR: "mc13xxx_get_num_regulators_dt" [drivers/regulator/mc13892-regulator.ko] undefined! Reported-by: Randy Dunlap <rdunlap@xenotime.net> Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* regulator: max8997: Avoid spaces in regulator namesKarol Lewandowski2012-01-241-4/+4
| | | | | | | | | | | | max8997-pmic instantiated from device tree uses names, not numerical ids to distinguish between outputs. Replace spaces with underscores in said names to make it possible to describe these outputs as regulators in DTS. Signed-off-by: Karol Lewandowski <k.lewandowsk@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* regulator: tps65910: use appropriate variable names.Laxman Dewangan2012-01-201-41/+41
| | | | | | | | | Renaming the variables "table" to "voltage_table" and "table_len" to "n_voltages" of regulator information to have more meaningful. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* regulator: tps65910: Initialize n_voltages for rails.Laxman Dewangan2012-01-201-0/+11
| | | | | | | | Initializing the number of voltages supported by different rails of pmic device tps65911. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* regulator: tps65910: Add regulator info for RTC railLaxman Dewangan2012-01-201-0/+3
| | | | | | | | | Adding missing regulator info for VRTC rail for device tps65911. The regulator voltage rail index start from VRTC which is defined as 0. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* regulator: Update s5m8767 for device tree API changesMark Brown2012-01-201-1/+1
| | | | Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* regulator: Update tps65217-regulator for DT changesAxel Lin2012-01-201-1/+1
| | | | | Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* regulator: tps65217: Add tps65217 regulator driverAnilKumar Ch2012-01-203-0/+503
| | | | | | | | | | | This patch adds tps65217 PMIC as a regulator The regulator module consists of 3 DCDCs and 4 LDOs. The output voltages are configurable and are meant to supply power to the main processor and other components Signed-off-by: AnilKumar Ch <anilkumar@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* regulator: Add S5M8767 configurationSangbeom Kim2012-01-202-0/+10
| | | | | | | This patch add Samsung S5M8767A pmic configuration. Signed-off-by: Sangbeom Kim <sbkim73@samsung.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* regulators/db8500: split off shared dbx500 codeBengt Jonsson2012-01-205-86/+341
| | | | | | | | | | | | | As we progress with DB5500 and future voltage domain regulators based on very similar hardware as found in the DB8500 PRCMU, it makes sense to split off the generic parts and introduce some generic debug code for the DBx500 regulators. This patch accoplish a basic abstraction of the DBx500 voltage domain regulators. Signed-off-by: Bengt Jonsson <bengt.g.jonsson@stericsson.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* regulator: s5m8767: Remove redundant MODULE_ALIASAxel Lin2012-01-201-1/+0
| | | | | | | | | The MODULE_DEVICE_TABLE will setup the modalias, thus adding a MODULE_ALIAS for an entry already in s5m8767_pmic_id is redundant. Signed-off-by: Axel Lin <axel.lin@gmail.com> Acked-by: Sangbeom Kim <sbkim73@samsung.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* regulator: s5m8767: Add missing breaksAxel Lin2012-01-201-0/+4
| | | | | | Signed-off-by: Axel Lin <axel.lin@gmail.com> Acked-by: Sangbeom Kim <sbkim73@samsung.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* regulator: Add S5M8767A regulator driverSangbeom Kim2012-01-201-0/+834
| | | | | | | | | | | S5M8767A is a cost-effective PMIC which is designed for mobile applications. It includes high efficient 9 Buck converters, 28 LDOs. Especially, S5M8767A is optimized for Multi-core SOCs. And during DVFS operation, S5M8767A output stable voltage. This patch implement regulator driver for S5M8767A. Signed-off-by: Sangbeom Kim <sbkim73@samsung.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* regulator: TPS62360: Add tps62360 regulator driverLaxman Dewangan2012-01-203-0/+483
| | | | | | | | | The regulator module consists of 1 DCDC. The output voltage is configurable and is meant for supply power to the core voltage of Soc. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* Merge branch 'for-next' of ↵Linus Torvalds2012-01-141-1/+1
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/sameo/mfd-2.6 * 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/sameo/mfd-2.6: (59 commits) rtc: max8925: Add function to work as wakeup source mfd: Add pm ops to max8925 mfd: Convert aat2870 to dev_pm_ops mfd: Still check other interrupts if we get a wm831x touchscreen IRQ mfd: Introduce missing kfree in 88pm860x probe routine mfd: Add S5M series configuration mfd: Add s5m series irq driver mfd: Add S5M core driver mfd: Improve mc13xxx dt binding document mfd: Fix stmpe section mismatch mfd: Fix stmpe build warning mfd: Fix STMPE I2c build failure mfd: Constify aat2870-core i2c_device_id table gpio: Add support for stmpe variant 801 mfd: Add support for stmpe variant 801 mfd: Add support for stmpe variant 610 mfd: Add support for STMPE SPI interface mfd: Separate out STMPE controller and interface specific code misc: Remove max8997-muic sysfs attributes mfd: Remove unused wm831x_irq_data_to_mask_reg() ... Fix up trivial conflict in drivers/leds/Kconfig due to addition of LEDS_MAX8997 and LEDS_TCA6507 next to each other.
| * mfd: Unify abx500 headers in mfd/abx500Linus Walleij2012-01-091-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | This moves all the header files related to the abx500 family into a common include directory below mfd. From now on we place any subchip header in that directory. Headers previously in e.g. <linux/mfd/ab8500/gpio.h> get prefixed and are now e.g. <linux/mfd/abx500/ab8500-gpio.h>. The top-level abstract interface remains in <linux/mfd/abx500.h>. Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
* | regulator: set constraints.apply_uV to 0 in of_get_fixed_voltage_configRichard Zhao2012-01-061-0/+1
| | | | | | | | | | | | | | | | | | | | Fix fixed regulator using DT failed to call regulator_register. of_get_regulator_init_data set apply_uV to 1, but fixed regulator doesn't need it. Set it back to 0. Signed-off-by: Richard Zhao <richard.zhao@linaro.org> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | regulator: max8925: fix enabled/disabled judgement mistakeKevin Liu2012-01-061-13/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Max8925 ldo status should be determined by two factors: 1. power up/down sequence selection(LDOCTL[4:2]). 2. i2c enable bit(LDOCTL[0]). Max8925 ldo support two types of power up/down sequence: 1. flexible sequence(LDOCTL[4:2] = 0~6). 2. i2c sequence(LDOCTL[4:2] = 7). With flexible sequence selected, the ldo is enabled during power up by default. With i2c sequence selected, the ldo is controlled by the i2c enable bit(LDOCTL[0]). Signed-off-by: Kevin Liu <kliu5@marvell.com> Signed-off-by: Haojian Zhuang <haojian.zhuang@marvell.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | regulator: add regulator_bulk_force_disable functionDonggeun Kim2012-01-031-0/+37
| | | | | | | | | | | | | | | | | | | | This patch allows consumers to forcibly disable multiple regulator clients in a single API call. Signed-off-by: Donggeun Kim <dg77.kim@samsung.com> Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | regulator: pass regulator_register of_node in fixed voltage driverRichard Zhao2012-01-021-1/+2
| | | | | | | | | | | | | | regulator_get needs of_node to find right regulator. Signed-off-by: Richard Zhao <richard.zhao@linaro.org> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | regulator: Enable supply regulator if child rail is enabled.Laxman Dewangan2012-01-021-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | During regulator_register, the rail is set on the provided machine constraints and if it is enabled then it is also require to enable the supply regulator. This will make sure that: 1. Proper reference count for supply regulator to be maintain. 2. Supply regulator should be enable when given rail is enabled. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | regulator: mc13892: Convert to devm_kzalloc()Fabio Estevam2011-12-301-3/+1
| | | | | | | | | | | | | | Convert mc13892-regulator driver to use devm_kzalloc(). Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | regulator: mc13783: Convert to devm_kzalloc()Fabio Estevam2011-12-291-4/+1
| | | | | | | | | | | | | | Convert mc13783-regulator driver to use devm_kzalloc(). Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | regulator: Fix checking return value of create_regulatorAxel Lin2011-12-291-3/+2
| | | | | | | | | | | | | | create_regulator() returns NULL on fail. Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | regulator: Fix the error handling if create_regulator failsAxel Lin2011-12-291-0/+1
| | | | | | | | | | | | | | | | In the case of create_regulator() fails, goto the error path immediately. It does not make sense to update rdev->open_count if create_regulator fails. Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | regulator: Export regulator_is_supported_voltage()Mark Brown2011-12-281-0/+1
| | | | | | | | | | | | It's part of the driver interface so should be available to modules. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | regulator: mc13892: add device tree probe supportShawn Guo2011-12-223-11/+109
| | | | | | | | | | | | | | It adds device tree probe support for mc13892-regulator driver. Signed-off-by: Shawn Guo <shawn.guo@linaro.org> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | regulator: mc13892: remove the unnecessary prefix from regulator nameShawn Guo2011-12-221-3/+3
| | | | | | | | | | | | | | | | | | It's not really necessary to add a prefix 'MC13892__' for each mc13892 regulator name, since the chip must have been identified as mc13892 when we look at the regulator name. Signed-off-by: Shawn Guo <shawn.guo@linaro.org> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | regulator: Convert wm831x regulator drivers to devm_kzalloc()Mark Brown2011-12-203-18/+9
| | | | | | | | Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | regulator: da9052: Staticize non-exported symbolsAxel Lin2011-12-201-2/+2
| | | | | | | | | | | | | | | | da9052_regulator_info and da9053_regulator_info are not used outside this driver so no need to make the symbol global. Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | regulator: Replace kzalloc with devm_kzalloc and if-else with a switch-case ↵Ashish Jangam2011-12-171-5/+11
| | | | | | | | | | | | | | | | | | for da9052-regulator Reported-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: David Dajun Chen <dchen@diasemi.com> Signed-off-by: Ashish Jangam <ashish.jangam@kpitcummins.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | regulator: Update da9052-regulator for DT changesMark Brown2011-12-151-1/+1
| | | | | | | | | | Reported-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | regulator: DA9052/53 Regulator supportAshish Jangam2011-12-143-0/+608
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The Dialog PMIC has below featured regulators:- DA9052-BC - 4 DVS Buck converters 0.5V - 3.6V upto 1Amp. DA9053-AA/BX - 4 DVS Buck converters 0.5V - 2.5V upto 3Amp. DA9052/53 - 10 Programmable LDO's High PSSR, 1% accuracy. This patch support all the DA9052 and Da9053 regulators. The output voltages are fully programmable via I2C or SPI interface. The platform data with regulation constraints is passed down from the board to the regulator. Signed-off-by: David Dajun Chen <dchen@diasemi.com> Signed-off-by: Ashish Jangam <ashish.jangam@kpitcummins.com> Tested-by: Ying-Chun Liu (PaulLiu) <paul.liu@linaro.org> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | Merge branch 'topic/dt' of ↵Mark Brown2011-12-052-4/+8
|\ \ | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator into regulator-next
| * | regulator: pass device_node to of_get_regulator_init_data()Shawn Guo2011-12-052-4/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It's not always true that the device_node of regulator can be found at dev->of_node at the time when of_get_regulator_init_data() is being called, because in some cases the regulator nodes in device tree do not have 'struct device' behind them until regulator_dev gets created for it by core function regulator_register(). The patch adds device_node as a new parameter to of_get_regulator_init_data(), so that caller can pass in the node of regulator directly. Signed-off-by: Shawn Guo <shawn.guo@linaro.org> Cc: Mark Brown <broonie@opensource.wolfsonmicro.com> Cc: Liam Girdwood <lrg@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| * | regulator: If a single voltage is set with device tree then set apply_uVMark Brown2011-12-051-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | Otherwise there is no way in the bindings to configure a fixed voltage via software. It seems reasonable to assume that if the binding explicitly specifies a voltage we want to actually use that voltage. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | | regulator: Allow regulators to register with no init_dataMark Brown2011-11-301-18/+25
| | | | | | | | | | | | | | | | | | | | | | | | This allows read-only access to the device configuration which may be useful for diagnostics. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
| | |
| \ \
*-. \ \ Merge remote-tracking branches 'regulator/topic/dt' and ↵Mark Brown2011-11-281-2/+44
|\ \ \ \ | | |/ / | |/| / | | |/ 'regulator/for-linus' into regulator-next
| | * regulator: twl: fix twl4030 support for smps regulatorsTero Kristo2011-11-281-2/+44
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | SMPS regulator voltage control differs from the one of the LDO ones. Current TWL code was using LDO regulator ops for controlling the SMPS regulators, which fails. This was fixed fixed by adding separate regulator type which uses correct logic and calculations for the voltage levels. Signed-off-by: Tero Kristo <t-kristo@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Cc: stable@kernel.org
* | | Merge remote-tracking branch 'regulator/for-linus' into regulator-nextMark Brown2011-11-281-1/+1
|\ \ \ | | |/ | |/|
| * | regulator: fix use after free bugLothar Waßmann2011-11-281-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is caused by dereferencing 'rdev' after device_unregister() in the regulator_unregister() function. 'rdev' is freed by device_unregister(), so it must not be dereferenced after this call. [Edited commit message for legibility -- broonie] Signed-off-by: Lothar Waßmann <LW@KARO-electronics.de> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | | Merge remote-tracking branch 'regulator/for-linus' into regulator-nextMark Brown2011-11-281-1/+1
|\| |
| * | regulator: aat2870: Fix the logic of checking if no id is matched in ↵Axel Lin2011-11-281-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | aat2870_get_regulator In current implementation, the pointer ri is not NULL if no id is matched. Fix it by checking i == ARRAY_SIZE(aat2870_regulators) if no id is matched. Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Cc: stable@kernel.org
* | | regulator: Convert virtual and userspace regulator consumer drivers to use ↵Axel Lin2011-11-282-23/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | module_platform_driver() This patch converts virtual and userspace regulator consumer drivers to use the module_platform_driver() macro which makes the code smaller and a bit simpler. Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | | regulator: aat2870: Remove a redundant bitwise and operationAxel Lin2011-11-281-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | The implementation in aat2870_update() already did the bitwise and operation against mask parameter. Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | | Merge remote-tracking branch 'regulator/topic/dt' into regulator-nextMark Brown2011-11-271-1/+6
|\ \ \ | | |/ | |/|
| * | regulator: Avoid potential NULL dereference in reg_fixed_voltage_probe()Axel Lin2011-11-271-1/+6
| | | | | | | | | | | | | | | | | | | | | | | | of_get_fixed_voltage_config() may return NULL, return -ENOMEM in this case so we don't dereference NULL pointer. Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | | Merge remote-tracking branch 'regulator/topic/dt' into regulator-nextMark Brown2011-11-272-1/+7
|\| |