aboutsummaryrefslogtreecommitdiff
path: root/drivers/regulator
AgeCommit message (Collapse)Author
2015-03-26regulator: core: Fix enable GPIO reference countingDoug Anderson
commit 29d62ec5f87fbeec8413e2215ddad12e7f972e4c upstream. Normally _regulator_do_enable() isn't called on an already-enabled rdev. That's because the main caller, _regulator_enable() always calls _regulator_is_enabled() and only calls _regulator_do_enable() if the rdev was not already enabled. However, there is one caller of _regulator_do_enable() that doesn't check: regulator_suspend_finish(). While we might want to make regulator_suspend_finish() behave more like _regulator_enable(), it's probably also a good idea to make _regulator_do_enable() robust if it is called on an already enabled rdev. At the moment, _regulator_do_enable() is _not_ robust for already enabled rdevs if we're using an ena_pin. Each time _regulator_do_enable() is called for an rdev using an ena_pin the reference count of the ena_pin is incremented even if the rdev was already enabled. This is not as intended because the ena_pin is for something else: for keeping track of how many active rdevs there are sharing the same ena_pin. Here's how the reference counting works here: * Each time _regulator_enable() is called we increment rdev->use_count, so _regulator_enable() calls need to be balanced with _regulator_disable() calls. * There is no explicit reference counting in _regulator_do_enable() which is normally just a warapper around rdev->desc->ops->enable() with code for supporting delays. It's not expected that the "ops->enable()" call do reference counting. * Since regulator_ena_gpio_ctrl() does have reference counting (handling the sharing of the pin amongst multiple rdevs), we shouldn't call it if the current rdev is already enabled. Note that as part of this we cleanup (remove) the initting of ena_gpio_state in regulator_register(). In _regulator_do_enable(), _regulator_do_disable() and _regulator_is_enabled() is is clear that ena_gpio_state should be the state of whether this particular rdev has requested the GPIO be enabled. regulator_register() was initting it as the actual state of the pin. Fixes: 967cfb18c0e3 ("regulator: core: manage enable GPIO list") Signed-off-by: Doug Anderson <dianders@chromium.org> Signed-off-by: Mark Brown <broonie@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-26regulator: Only enable disabled regulators on resumeJavier Martinez Canillas
commit 0548bf4f5ad6fc3bd93c4940fa48078b34609682 upstream. The _regulator_do_enable() call ought to be a no-op when called on an already-enabled regulator. However, as an optimization _regulator_enable() doesn't call _regulator_do_enable() on an already enabled regulator. That means we never test the case of calling _regulator_do_enable() during normal usage and there may be hidden bugs or warnings. We have seen warnings issued by the tps65090 driver and bugs when using the GPIO enable pin. Let's match the same optimization that _regulator_enable() in regulator_suspend_finish(). That may speed up suspend/resume and also avoids exposing hidden bugs. [Use much clearer commit message from Doug Anderson] Signed-off-by: Javier Martinez Canillas <javier.martinez@collabora.co.uk> Signed-off-by: Mark Brown <broonie@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-02-05regulator: core: fix race condition in regulator_put()Ashay Jaiswal
commit 83b0302d347a49f951e904184afe57ac3723476e upstream. The regulator framework maintains a list of consumer regulators for a regulator device and protects it from concurrent access using the regulator device's mutex lock. In the case of regulator_put() the consumer is removed and regulator device's parameters are updated without holding the regulator device's mutex. This would lead to a race condition between the regulator_put() and any function which traverses the consumer list or modifies regulator device's parameters. Fix this race condition by holding the regulator device's mutex in case of regulator_put. Signed-off-by: Ashay Jaiswal <ashayj@codeaurora.org> Signed-off-by: Mark Brown <broonie@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-14regulator: max77693: Fix use of uninitialized regulator configKrzysztof Kozlowski
commit ca0c37a0b489bb14bf3e1549e7a8d0c9a17f4919 upstream. Driver allocated on stack struct regulator_config but didn't initialize it fully. Few fields (driver_data, ena_gpio) were left untouched. This lead to using random ena_gpio values as GPIOs for max77693 regulators. On occasion these values could match real GPIO numbers leading to interfering with other drivers and to unsuccessful enable/disable of regulator. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Fixes: 80b022e29bfd ("regulator: max77693: Add max77693 regualtor driver.") Signed-off-by: Mark Brown <broonie@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-09-17regulator: arizona-ldo1: remove bypass functionalityNikesh Oswal
commit 5b919f3ebb533cbe400664837e24f66a0836b907 upstream. WM5110/8280 devices do not support bypass mode for LDO1 so remove the bypass callbacks registered with regulator core. Signed-off-by: Nikesh Oswal <nikesh@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-06regulator: arizona-ldo1: Correct default regulator init_dataCharles Keepax
commit a35ff2861690eaf9dbb38fa744a8a9e6f4ebfd61 upstream. Both 5102 and 8997 have the regulator capable of supplying 1.8V, and the voltage step from the 5110 regulator is different from what is specified in the default description. This patch updates the default regulator description to match 5110 and selects the 1.8V capable description for 8997. Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-04Merge tag 'regulator-v3.14-rc5' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator Pull regulator fixes from Mark Brown: "A couple of fixes here which ensure that regulators using the core support for GPIO enables work in all cases by ensuring that helpers are used consistently rather than open coding in places and hence not having GPIO support in some of them" * tag 'regulator-v3.14-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator: regulator: core: Replace direct ops->disable usage regulator: core: Replace direct ops->enable usage
2014-02-25regulator: core: Replace direct ops->disable usageMarkus Pargmann
There are many places where ops->disable is called directly. Instead we should use _regulator_do_disable() which also handles gpio regulators. To be able to use the wrapper function from _regulator_force_disable(), I moved the _notifier_call_chain() call from _regulator_do_disable() to _regulator_disable(). This way, _regulator_force_disable() can use different flags for _notifier_call_chain() without calling it twice. Cc: <stable@vger.kernel.org> # 3.10+ Signed-off-by: Markus Pargmann <mpa@pengutronix.de> Signed-off-by: Mark Brown <broonie@linaro.org>
2014-02-25regulator: core: Replace direct ops->enable usageMarkus Pargmann
There are some direct ops->enable in the regulator core driver. This is a potential issue as the function _regulator_do_enable() handles gpio regulators and the normal ops->enable calls. These gpio regulators are simply ignored when ops->enable is called directly. One possible bug is that boot-on and always-on gpio regulators are not enabled on registration. This patch replaces all ops->enable calls by _regulator_do_enable. [Handle missing enable operations -- broonie] Cc: <stable@vger.kernel.org> # 3.10+ Signed-off-by: Markus Pargmann <mpa@pengutronix.de> Signed-off-by: Mark Brown <broonie@linaro.org> regulator: Handle invalid enable operation for always/boot on regulators Signed-off-by: Mark Brown <broonie@linaro.org>
2014-02-23Merge remote-tracking branches 'regulator/fix/da9063', ↵Mark Brown
'regulator/fix/max14577' and 'regulator/fix/s5m8767' into regulator-linus
2014-02-23Merge remote-tracking branch 'regulator/fix/core' into regulator-linusMark Brown
2014-02-22regulator: max14577: Fix invalid return value on DT parse successKrzysztof Kozlowski
This fixes bug introduced in 667a6b7a (regulator: max14577: Add missing of_node_put). The DTS parsing function returned number of matched regulators as success status which then was compared against 0 in probe. Result was a probe fail after successful parsing the DTS: max14577-regulator: probe of max14577-regulator failed with error 2 Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Reviwed-by: Sachin Kamat <sachin.kamat@linaro.org> Signed-off-by: Mark Brown <broonie@linaro.org>
2014-02-21regulator: core: Change dummy supplies error message to a warningShuah Khan
Change "dummy supplies not allowed" error message to warning instead, as this is a just warning message with no change to the behavior. [Added a CC to stable since some other bug fixes cause this to come up more frequently on PCs which is how it was noticed -- broonie] Signed-off-by: Shuah Khan <shuah.kh@samsung.com> Signed-off-by: Mark Brown <broonie@linaro.org> Cc: stable@vger.kernel.org
2014-02-13regulator: s5m8767: Add missing of_node_putSachin Kamat
Add of_node_put to decrement the ref count. Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Signed-off-by: Mark Brown <broonie@linaro.org>
2014-02-13regulator: s5m8767: Use of_get_child_by_nameSachin Kamat
of_find_node_by_name walks the allnodes list, and can thus walk outside of the parent node. Use of_get_child_by_name instead. Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Signed-off-by: Mark Brown <broonie@linaro.org>
2014-02-12regulator: da9063: Bug fix when setting max voltage on LDOs 5-11Steve Twiss
Bug fix to allow the setting of maximum voltage for certain LDOs. What the bug is: There is a problem caused by an invalid calculation of n_voltages in the driver. This n_voltages value has the potential to be different for each regulator. The value for linear_min_sel is set as DA9063_V##regl_name# which can be different depending upon the regulator. This is chosen according to the following definitions in the DA9063 registers.h file: DA9063_VLDO1_BIAS 0 DA9063_VLDO2_BIAS 0 DA9063_VLDO3_BIAS 0 DA9063_VLDO4_BIAS 0 DA9063_VLDO5_BIAS 2 DA9063_VLDO6_BIAS 2 DA9063_VLDO7_BIAS 2 DA9063_VLDO8_BIAS 2 DA9063_VLDO9_BIAS 3 DA9063_VLDO10_BIAS 2 DA9063_VLDO11_BIAS 2 The calculation for n_voltages is valid for LDOs whose BIAS value is zero but this is not correct for those LDOs which have a non-zero value. What the fix is: In order to take into account the non-zero linear_min_sel value which is set for the regulators LDO5, LDO6, LDO7, LDO8, LDO9, LDO10 and LDO11, the calculation for n_voltages should take into account the missing term defined by DA9063_V##regl_name#. This will in turn allow the core constraints calculation to set the maximum voltage limits correctly and therefore allow users to apply the maximum expected voltage to all of the LDOs. Signed-off-by: Steve Twiss <stwiss.opensource@diasemi.com> Signed-off-by: Mark Brown <broonie@linaro.org> Cc: stable@vger.kernel.org
2014-02-12Merge remote-tracking branches 'regulator/fix/da9055' and ↵Mark Brown
'regulator/fix/max14577' into regulator-linus
2014-02-07regulator: da9055: Remove use of regmap_irq_get_virq()Adam Thomson
Signed-off-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2014-02-05regulator: max14577: Add missing of_node_putKrzysztof Kozlowski
Decrease the reference count for 'regulators' device_node, obtained by of_get_child_by_name(). Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2014-02-04Merge remote-tracking branches 'regulator/fix/ab3100' and ↵Mark Brown
'regulator/fix/s2mps11' into regulator-linus
2014-02-04Merge remote-tracking branch 'regulator/fix/core' into regulator-linusMark Brown
2014-01-31regulator: s2mps11: Fix NULL pointer of_node value when using platform dataKrzysztof Kozlowski
When platform_data is used for regulator (of_node of sec-core MFD device is NULL) the config.of_node for regulator is not initialized. This NULL value of config.of_node is later stored during regulator_register(). Thus any call by regulator consumers to of_get_regulator() will fail on of_parse_phandle() returning NULL. In this case (using platform_data and parent's driver of_node is NULL) set the config.of_node to reg_node from platform_data. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2014-01-28regulator: core: Correct default return value for full constraintsMark Brown
Once we have full constraints then all supply mappings should be known to the regulator API. This means that we should treat failed lookups as fatal rather than deferring in the hope of further registrations but this was broken by commit 9b92da1f1205bd25 "regulator: core: Fix default return value for _get()" which was targeted at DT systems but unintentionally broke non-DT systems by changing the default return value. Fix this by explicitly returning -EPROBE_DEFER from the DT lookup if we find a property but no corresponding regulator and by having the non-DT case default to -ENODEV when we have full constraints. Fixes: 9b92da1f1205bd25 "regulator: core: Fix default return value for _get()" Signed-off-by: Mark Brown <broonie@linaro.org> Tested-by: Guenter Roeck <linux@roeck-us.net> Cc: stable@vger.kernel.org
2014-01-25Merge tag 'regulator-v3.14-2' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator Pull regulator updates from Mark Brown: "A respin of the merges in the previous pull request with one extra fix. A quiet release for the regulator API, quite a large number of small improvements all over but other than the addition of new drivers for the AS3722 and MAX14577 there is nothing of substantial non-local impact" * tag 'regulator-v3.14-2' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator: (47 commits) regulator: pfuze100-regulator: Improve dev_info() message regulator: pfuze100-regulator: Fix some checkpatch complaints regulator: twl: Fix checkpatch issue regulator: core: Fix checkpatch issue regulator: anatop-regulator: Remove unneeded memset() regulator: s5m8767: Update LDO index in s5m8767-regulator.txt regulator: as3722: set enable time for SD0/1/6 regulator: as3722: detect SD0 low-voltage mode regulator: tps62360: Fix up a pointer-integer size mismatch warning regulator: anatop-regulator: Remove unneeded kstrdup() regulator: act8865: Fix build error when !OF regulator: act8865: register all regulators regardless of how many are used regulator: wm831x-dcdc: Remove unneeded 'err' label regulator: anatop-regulator: Add MODULE_ALIAS() regulator: act8865: fix incorrect devm_kzalloc for act8865 regulator: act8865: Remove set_suspend_[en|dis]able implementation regulator: act8865: Remove unneeded regulator_unregister() calls regulator: s2mps11: Clean up redundant code regulator: tps65910: Simplify setting enable_mask for regulators regulator: act8865: add device tree binding doc ...
2014-01-23regulator: ab3100: cast fixLinus Walleij
The AB3100 regulator driver emits a warning when compiled on 64bit systems like this: drivers/regulator/ab3100.c: In function ‘ab3100_regulator_of_probe’: srivers/regulator/ab3100.c:649:4: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast] As the int is a different size than the 64bit pointer used to pass regulator data. Switch to using an unsigned long as ID passed for the regulator to get rid of the warning. Reported-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Mark Brown <broonie@linaro.org>
2014-01-23Merge remote-tracking branches 'regulator/topic/s2mps11', ↵Mark Brown
'regulator/topic/s5m8767', 'regulator/topic/stw481x-vmmc', 'regulator/topic/tps51632', 'regulator/topic/tps62360', 'regulator/topic/tps65910', 'regulator/topic/twl' and 'regulator/topic/wm831x' into regulator-linus
2014-01-23Merge remote-tracking branches 'regulator/topic/db8500', ↵Mark Brown
'regulator/topic/gpio', 'regulator/topic/lp3971', 'regulator/topic/lp3972', 'regulator/topic/max14577', 'regulator/topic/max77693', 'regulator/topic/mc13892', 'regulator/topic/pcf50633' and 'regulator/topic/pfuze100' into regulator-linus
2014-01-23Merge remote-tracking branches 'regulator/fix/pfuze100', ↵Mark Brown
'regulator/fix/s5m8767', 'regulator/topic/ab8500', 'regulator/topic/act8865', 'regulator/topic/anatop', 'regulator/topic/arizona' and 'regulator/topic/as3722' into regulator-linus
2014-01-23Merge remote-tracking branch 'regulator/topic/core' into regulator-linusMark Brown
2014-01-23regulator: pfuze100-regulator: Improve dev_info() messageFabio Estevam
'lay' is not very meaningful, so use it 'layer' instead to let the dev_info() clearer. Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2014-01-21mfd: mc13xxx: Remove useless symbol MFD_MC13783Alexander Shiyan
Symbol MFD_MC13783 always selected by MFD_MC13XXX, so no need to keep additional symbol. Signed-off-by: Alexander Shiyan <shc_work@mail.ru> Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-01-21regulator: tps6586x: Add and use correct voltage tableStefan Agner
Depending on the regulator version, the voltage table might be different. Use version specific regulator tables in order to select correct voltage table. For the following regulator versions different voltage tables are now used: * TPS658623: Use correct voltage table for SM2 * TPS658643: New voltage table for SM2 Both versions are in use on the Colibri T20 module. Make use of the correct tables by requesting the correct SM2 voltage of 1.8V. This change is not backward compatible since an old driver is not able to correctly set that value. The value 1.8V is out of range for the old driver and will refuse to probe the device. The regulator starts with default settings and the driver shows appropriate error messages. On Colibri T20, the old value used to work with TPS658623 since the driver applied a wrong voltage table too. However, the TPS658643 used on V1.2 devices uses yet another voltage table and those broke that pseudo-compatibility. The regulator driver now has the correct voltage table for both regulator versions and those the correct voltage can be used in the device tree. Signed-off-by: Stefan Agner <stefan@agner.ch> Reviewed-by: Thierry Reding <treding@nvidia.com> Acked-by: Mark Brown <broonie@linaro.org> Acked-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-01-15regulator: pfuze100-regulator: Fix some checkpatch complaintsFabio Estevam
Fix the following checkpatch error and warning: ERROR: switch and case should be at the same indent #311: FILE: drivers/regulator/pfuze100-regulator.c:311: + switch (value & 0x0f) { [...] + case 0x8: [...] + case 0x0: [...] + default: WARNING: line over 80 characters #312: FILE: drivers/regulator/pfuze100-regulator.c:312: + /* Freescale misprogrammed 1-3% of parts prior to week 8 of 2013 as ID=8 */ Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2014-01-15Merge tag 'v3.13-rc4' into regulator-pfuze100Mark Brown
Linux 3.13-rc4
2014-01-08regulator: twl: Fix checkpatch issueJingoo Han
Fix the following checkpatch warnings. WARNING: please, no space before tabs WARNING: space prohibited between function name and open parenthesis '(' Signed-off-by: Jingoo Han <jg1.han@samsung.com> Acked-by: Nishanth Menon <nm@ti.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2014-01-08regulator: core: Fix checkpatch issueJingoo Han
Fix the following checkpatch errors and warnings. ERROR: trailing whitespace ERROR: return is not a function, parentheses are not required WARNING: braces {} are not necessary for single statement blocks Signed-off-by: Jingoo Han <jg1.han@samsung.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2014-01-08regulator: anatop-regulator: Remove unneeded memset()Fabio Estevam
sreg is allocated via devm_kzalloc(), so there is no need to explicitly zero out rdesc via memset(). Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2014-01-06regulator: as3722: set enable time for SD0/1/6Vince Hsu
Add an enable time of 600us for SD0/1/6 to ensure that we have enough setup time for the power rail. Signed-off-by: Vince Hsu <vinceh@nvidia.com> Signed-off-by: Andrew Bresticker <abrestic@chromium.org> Signed-off-by: Mark Brown <broonie@linaro.org>
2014-01-06regulator: as3722: detect SD0 low-voltage modeAndrew Bresticker
SD0 may operate in low-voltage mode, with a minimum of 0.41V and a maximum of 1.5V. This is indicated by bit 4 of FUSE7. Signed-off-by: Andrew Bresticker <abrestic@chromium.org> Signed-off-by: Vince Hsu <vinceh@nvidia.com> broonie.e6264@m.evernote.com Signed-off-by: Mark Brown <broonie@linaro.org>
2014-01-06regulator: tps62360: Fix up a pointer-integer size mismatch warningDavid Howells
Fix up the following pointer-integer size mismatch warning in tps62360_probe(): drivers/regulator/tps62360-regulator.c: In function 'tps62360_probe': drivers/regulator/tps62360-regulator.c:363:13: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast] chip_id = (int)match->data; ^ Signed-off-by: David Howells <dhowells@redhat.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2014-01-06regulator: anatop-regulator: Remove unneeded kstrdup()Fabio Estevam
We can simply pass the regulator name via of_get_property() instead of making a copy via kstrdup(). This leads to some code simplification. Suggested-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2014-01-06regulator: act8865: Fix build error when !OFAxel Lin
Fix below build error when !OF: CC [M] drivers/regulator/act8865-regulator.o drivers/regulator/act8865-regulator.c: In function 'act8865_pmic_probe': drivers/regulator/act8865-regulator.c:306:18: error: 'act8865_matches' undeclared (first use in this function) drivers/regulator/act8865-regulator.c:306:18: note: each undeclared identifier is reported only once for each function it appears in drivers/regulator/act8865-regulator.c:306:18: error: negative width in bit-field '<anonymous>' make[2]: *** [drivers/regulator/act8865-regulator.o] Error 1 make[1]: *** [drivers/regulator] Error 2 make: *** [drivers] Error 2 Reported-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-31regulator: act8865: register all regulators regardless of how many are usedWenyou Yang
As Mark pointed out, the driver should register all regulators regardless of how many are used in the system in order to aid diagnostics. But in the previous patch, only register the regulators that are used. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-31regulator: wm831x-dcdc: Remove unneeded 'err' labelFabio Estevam
There is no need to jump to the 'err' label. Returnn the error directly instead. Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-31regulator: anatop-regulator: Add MODULE_ALIAS()Fabio Estevam
Provide a MODULE_ALIAS() entry to the driver. Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-30regulator: act8865: fix incorrect devm_kzalloc for act8865Wenyou Yang
Which cause to allocate more needless memory. Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-30regulator: act8865: Remove set_suspend_[en|dis]able implementationAxel Lin
There is no suspend enable/disable settings mentioned in datasheet, so just don't implement .set_suspend_[en|dis]able callbacks. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-30regulator: act8865: Remove unneeded regulator_unregister() callsAxel Lin
This is not required because current code use devm_regulator_register() to register regulators. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-30regulator: s2mps11: Clean up redundant codeSachin Kamat
BUCK 3 and 4 share the same ramp delay. Hence make it a fall through case instead of duplicating the code. Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Signed-off-by: Mark Brown <broonie@linaro.org>
2013-12-30regulator: tps65910: Simplify setting enable_mask for regulatorsAxel Lin
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>