aboutsummaryrefslogtreecommitdiff
path: root/drivers/regulator
AgeCommit message (Collapse)Author
2013-12-24regulator: act8865: add PMIC act8865 driverWenyou Yang
Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-24regulator: max77693: Add missing .owner field in regulator_descAxel Lin
Add missing .owner field in regulator_desc, which is used for refcounting. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-24regulator: pfuze100: Improve PFUZE100 entry textFabio Estevam
Make PFUZE100 entry consistent with other Freescale PMIC entries, so that now we can have: <*> Freescale MC13783 regulator driver <*> Freescale MC13892 regulator driver <*> Freescale PFUZE100 regulator driver Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Acked-by: Robin Gong <yibin.gong@freescale.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-23regulator: max14577: Add module alias to support module auto-loadingAxel Lin
Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-21regulator: tps65910: Add backup battery regulatorMarkus Pargmann
tps65910 has a backup battery charger with a configurable voltage. This patch adds a regulator for the backup battery. Signed-off-by: Markus Pargmann <mpa@pengutronix.de> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-21regulator: tps51632-regulator: Fix spellingFabio Estevam
Fix the 'VOLATGE' spell error. Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-20regulator: as3722: Don't set min_uV/uV_step/linear_min_sel for linear_rangesAxel Lin
These settings are not used when using linear_ranges and it makes the code looks confusing. Thus remove them. Signed-off-by: Axel Lin <axel.lin@ingics.com> Acked-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-18regulator: max14577: Add regulator driver for Maxim 14577Krzysztof Kozlowski
MAX14577 chip is a multi-function device which includes MUIC, charger and voltage regulator. The driver is located in drivers/mfd. This patch adds regulator driver for MAX14577 chip. There are two regulators in this chip: 1. Safeout LDO with constant voltage output of 4.9V. It can be only enabled or disabled. 2. Current regulator for the charger. It provides current from 90mA up to 950mA. Driver supports Device Tree. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-18Merge tag 's2mps11-build' into regulator-s5m8767 since a following patchMark Brown
depend on it. regulator/clk: Fix s2mps11 build This patch fixes a build failure that appeared in v3.13-rc4 due to an RTC/MFD update merged via -mm.
2013-12-18regulator: s5m8767: Do not use sec_reg* regmap helpersKrzysztof Kozlowski
Replace calls to sec_reg* helpers with direct usage of regmap API. The sec_reg* helpers are error-prone as they mix u8 with unsigned int and order of some of parameters (val and mask in sec_reg_update()). Also the helpers do not give any way of useful abstraction as they just call corresponding regmap function. This patch replaces: - sec_reg_read() with regmap_read(), - sec_reg_write() with regmap_write(), - sec_reg_update() with regmap_update_bits(). Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Acked-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-18regulator: s5m8767: Add symbols for hard-coded DVS_RAMP registerKrzysztof Kozlowski
Add symbols for hard-coded values of BUCK_RAMP field in DVS_RAMP register. This simplifies a little the code as register update is called only once. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Acked-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-17regulator: core: don't print an error when no regulator is foundHans de Goede
Only print an error when _regulator_get() is expected to return a valid regulator, that is when _regulator_get() is called from regulator_get() and we're not using the dummy because we don't have full-constraints, or when _regulator_get() is called from regulator_get_exclusive() in which case returning a dummy is not allowed. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-16mfd: s2mps11: Fix build after regmap field rename in sec-core.cKrzysztof Kozlowski
Fix building of s2mps11 regulator and clock drivers after renaming regmap field in struct sec_pmic_dev in commit: - "mfd/rtc: s5m: Fix register updating by adding regmap for RTC" Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Cc: Kyungmin Park <kyungmin.park@samsung.com> Cc: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-13Merge tag 'regulator-v3.13-rc3' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator Pull regulator fixes from Mark Brown: "A small set of driver fixes plus one larger core change which changes the way we check to see if we're using DT so that there aren't any races between deciding we're using DT and the regulator subsystem noticing. This makes the new support for substituting a dummy regulator and optional regulators work a lot better on DT systems since it ensures that we don't trigger probe deferral when we shouldn't which was causing bugs in clients" * tag 'regulator-v3.13-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator: regulator: pfuze100: allow misprogrammed ID regulator: pfuze100: Fix address of FABID regulator: as3722: set the correct current limit regulator: core: Check for DT every time we check full constraints regulator: core: Replace checks of have_full_constraints with a function
2013-12-13Merge remote-tracking branch 'regulator/topic/constraints' into regulator-linusMark Brown
2013-12-12mfd/rtc: s5m: fix register updating by adding regmap for RTCKrzysztof Kozlowski
Rename old regmap field of "struct sec_pmic_dev" to "regmap_pmic" and add new regmap for RTC. On S5M8767A registers were not properly updated and read due to usage of the same regmap as the PMIC. This could be observed in various hangs, e.g. in infinite loop during waiting for UDR field change. On this chip family the RTC has different I2C address than PMIC so additional regmap is needed. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Reviewed-by: Mark Brown <broonie@linaro.org> Acked-by: Sangbeom Kim <sbkim73@samsung.com> Cc: Samuel Ortiz <sameo@linux.intel.com> Cc: Lee Jones <lee.jones@linaro.org> Cc: Liam Girdwood <lgirdwood@gmail.com> Cc: Alessandro Zummo <a.zummo@towertech.it> Cc: Marek Szyprowski <m.szyprowski@samsung.com> Cc: Geert Uytterhoeven <geert@linux-m68k.org> Cc: Kyungmin Park <kyungmin.park@samsung.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2013-12-11Merge remote-tracking branches 'regulator/fix/as3722' and ↵Mark Brown
'regulator/fix/pfuze100' into regulator-linus
2013-12-11regulator: s5m8767: Implement voltage setting for BUCK7/8 regulatorsKrzysztof Kozlowski
Voltage setting for BUCK7 and BUCK8 was not supported by s5m8767 driver. If they were configured in DTS then the driver probing would fail with EINVAL: [ 0.288474] VCC_SUB_1.35V: failed to apply 1350000uV constraint [ 0.288671] s5m8767-pmic s5m8767-pmic: regulator init failed for 35 [ 0.294931] s5m8767-pmic: probe of s5m8767-pmic failed with error -22 This patch adds support for BUCK7 and BUCK8 regulators using standard regmap get/set voltage sel functions. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Reviewed-by: Sachin Kamat <sachin.kamat@linaro.org> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-11regulator: s5m8767: Define symbol for buck control maskKrzysztof Kozlowski
Replace hard-coded value for mask used in BUCKX_CTRL registers (for BUCKX_EN field) with a symbol. This also removes two local variables. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Acked-by: Lee Jones <lee.jones@linaro.org> Reviewed-by: Sachin Kamat <sachin.kamat@linaro.org> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-09regulator: pfuze100: use devm_regulator_register()Jingoo Han
Use devm_regulator_register() to make cleanup paths simpler, and remove unnecessary remove(). Signed-off-by: Jingoo Han <jg1.han@samsung.com> Acked-by: Robin Gong <b38343@freescale.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-09regulator: db8500-prcmu: use devm_regulator_register()Jingoo Han
Use devm_regulator_register() to make cleanup paths simpler. Signed-off-by: Jingoo Han <jg1.han@samsung.com> Acked-by: Bengt Jonsson <bengt.g.jonsson@stericsson.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-09regulator: ab8500: use devm_regulator_register()Jingoo Han
Use devm_regulator_register() to make cleanup paths simpler. Signed-off-by: Jingoo Han <jg1.han@samsung.com> Acked-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-09regulator: stw481x-vmmc: use devm_regulator_register()Jingoo Han
Use devm_regulator_register() to make cleanup paths simpler, and remove unnecessary remove(). Signed-off-by: Jingoo Han <jg1.han@samsung.com> Reviewed-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-09regulator: pfuze100: allow misprogrammed IDTim Harvey
prior to week 08 of 2013 Freescale misprogrammed between 1 and 3% of PFUZE1000 parts with a ID=0x8 instead of the expected ID=0x0 Signed-off-by: Tim Harvey <tharvey@gateworks.com> Signed-off-by: Mark Brown <broonie@linaro.org> Cc: stable@vger.kernel.org
2013-12-09regulator: pfuze100: Fix address of FABIDAxel Lin
According to the datasheet, the address of FABID is 0x4. Fix it. Signed-off-by: Axel Lin <axel.lin@ingics.com> Acked-by: Robin Gong <b38343@freescale.com> Signed-off-by: Mark Brown <broonie@linaro.org> Cc: stable@vger.kernel.org
2013-12-06regulator: gpio: Warn if an invalid regulator-type is suppliedMark Brown
Reported-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-05regulator: gpio: Don't require a regulator-type propertyMark Brown
Since essentially all GPIO controlled regulators are voltage regulators make the regulator-type property optional, defaulting to voltage. Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-03regulator: ab8500: delete non-devicetree probe pathLinus Walleij
The Ux500 platform has been converted to do device-tree only boots, no longer supports platform data passing, so this probe path is unused. Delete it, simplifying the driver a whole lot. Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Acked-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-02regulator: as3722: set the correct current limitVince Hsu
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
2013-12-02mfd: pcf50633: Correct device name for pcf50633 regulatorAxel Lin
Change the device name of the regulator function to the one chosen for MODULE_ALIAS. This fixes kernel auto-module loading for the regulator function. Signed-off-by: Axel Lin <axel.lin@ingics.com> Acked-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-11-27regulator: core: Check for DT every time we check full constraintsMark Brown
Eliminate the gap between DT becoming available and this being used to say we have full constraints by checking directly for DT every time we check for full constraints. This improves interoperaton with optional regulator support. Signed-off-by: Mark Brown <broonie@linaro.org> Tested-by: Fabio Estevam <fabio.estevam@freescale.com>
2013-11-27regulator: core: Replace checks of have_full_constraints with a functionMark Brown
Simple code reorganisation so we can change the logic for deciding what full constraints are more easily. Signed-off-by: Mark Brown <broonie@linaro.org>
2013-11-24Merge remote-tracking branch 'regulator/fix/pfuze100' into regulator-linusMark Brown
2013-11-24Merge remote-tracking branch 'regulator/fix/gpio' into regulator-linusMark Brown
2013-11-24Merge remote-tracking branch 'regulator/fix/fixed' into regulator-linusMark Brown
2013-11-24Merge remote-tracking branch 'regulator/fix/arizona' into regulator-linusMark Brown
2013-11-24regulator: lp3972: Convert to devm_regulator_registerAxel Lin
Both num_regulators and **rdev are no longer required after this conversion, thus remove them from struct lp3972. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-11-24regulator: arizona-micsupp: Convert to use linear rangesCharles Keepax
Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-11-24regulator: tps51632: Get regulator name from i2c_clientMikko Perttunen
Commit "i2c: core: make it possible to match a pure device tree driver" changed semantics of the i2c probing for device tree devices. Device tree probed devices now get a NULL i2c_device_id pointer. This causes the regulator name to be set to NULL and the regulator registration to fail. Signed-off-by: Mikko Perttunen <mperttunen@nvidia.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-11-15Merge branch 'for-linus' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial Pull trivial tree updates from Jiri Kosina: "Usual earth-shaking, news-breaking, rocket science pile from trivial.git" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial: (23 commits) doc: usb: Fix typo in Documentation/usb/gadget_configs.txt doc: add missing files to timers/00-INDEX timekeeping: Fix some trivial typos in comments mm: Fix some trivial typos in comments irq: Fix some trivial typos in comments NUMA: fix typos in Kconfig help text mm: update 00-INDEX doc: Documentation/DMA-attributes.txt fix typo DRM: comment: `halve' -> `half' Docs: Kconfig: `devlopers' -> `developers' doc: typo on word accounting in kprobes.c in mutliple architectures treewide: fix "usefull" typo treewide: fix "distingush" typo mm/Kconfig: Grammar s/an/a/ kexec: Typo s/the/then/ Documentation/kvm: Update cpuid documentation for steal time and pv eoi treewide: Fix common typo in "identify" __page_to_pfn: Fix typo in comment Correct some typos for word frequency clk: fixed-factor: Fix a trivial typo ...
2013-11-15regulator: arizona-micsupp: Correct wm5110 voltage selectionCharles Keepax
wm5110 provides different voltage configurations than the other Arizona parts, this patch adds support for this into the regulator driver. Also fixup the default for the configuration register for wm5110. Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@linaro.org> Cc: stable@vger.kernel.org (v3.12)
2013-11-14regulator: pfuze100: allow misprogrammed IDTim Harvey
prior to week 08 of 2013 Freescale misprogrammed between 1 and 3% of PFUZE1000 parts with a ID=0x8 instead of the expected ID=0x0 Signed-off-by: Tim Harvey <tharvey@gateworks.com> Signed-off-by: Mark Brown <broonie@linaro.org> Cc: stable@vger.kernel.org
2013-11-13regulator: fixed: fix regulator_list_voltage() for regressionGuennadi Liakhovetski
Commit c368e5fc2a190923b786f2de3e79430ea3566a25 "regulator: fixed: get rid of {get|list}_voltage()" broke regulator_list_voltage() for the fixed regulator, because an earlier commit 5a523605afa7d3b54b2e7041f8c9e6bc39872a7e "regulator: core: provide fixed voltage in desc for single voltage rail" missed to add support for the fixed-voltage special case to that function. This patch fixes that regression. Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Acked-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-11-13regulator: lp3971: Convert to devm_regulator_registerAxel Lin
Both num_regulators and **rdev are no longer required after this conversion, thus remove them from struct lp3971. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-11-09regulator: gpio-regulator: Don't oops on missing regulator-type propertyLaurent Pinchart
Catch missing regulator-type property in DT and return an error gracefully instead of deferencing a NULL pointer and crashing. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-10-24Merge remote-tracking branch 'regulator/topic/tps65910' into regulator-nextMark Brown
2013-10-24Merge remote-tracking branch 'regulator/topic/tps6586x' into regulator-nextMark Brown
2013-10-24Merge remote-tracking branch 'regulator/topic/tps65090' into regulator-nextMark Brown
2013-10-24Merge remote-tracking branch 'regulator/topic/tps65023' into regulator-nextMark Brown
2013-10-24Merge remote-tracking branch 'regulator/topic/tps6105x' into regulator-nextMark Brown