aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/regulator
Commit message (Collapse)AuthorAge
* ENGR00319166: regulator: anatop: correct vddpu regulator status in ↵Robin Gong2014-06-19
| | | | | | | | | | | | | | | | | | ldo-bypass mode In case ldo-bypass mode, we will use 'pureg_dummy' in stead of 'vddpu'.The voltage setting is 0x1f(ldo-mode) and the non-zero value means 'vddpu' enabled status. Regulator common framwork will turn off the unused regulator which keep enabled status. That will set the PU mode from ldo-bypass to power off, and may make gpu/vpu driver hang etc. You can also see the below abnormal message during boot: [ 3.000182] VFP support v0.3: implementor 41 architecture 3 part 30 variant 9 rev 4 [ 3.010577] VGEN3: disabling [ 3.015116] VGEN2: disabling [ 3.019659] VGEN1: disabling [ 3.023598] vddpu: disabling Signed-off-by: Robin Gong <b38343@freescale.com>
* pfuze100-regulator: Fix of_node_get() parameterFabio Estevam2014-04-16
| | | | | | | | | | | | | | | | | | Since commit d7857c42 (regulator: pfuze100: Use of_get_child_by_name) we get the following probe failure: pfuze100-regulator 1-0008: Full layer: 1, Metal layer: 0 pfuze100-regulator 1-0008: FAB: 0, FIN: 0 pfuze100-regulator 1-0008: regulators node not found pfuze100-regulator: probe of 1-0008 failed with error -22 Now that of_get_child_by_name() is used we should adjust the device_node pointer 'np' to not get the parent node anymore. Suggested-by: Shawn Guo <shawn.guo@linaro.org> Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Acked-by: Sachin Kamat <sachin.kamat@linaro.org> Signed-off-by: Mark Brown <broonie@linaro.org>
* regulator: pfuze100: Use of_get_child_by_nameSachin Kamat2014-04-16
| | | | | | | | 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>
* regulator: pfuze100: Add PFUZE200 support to Kconfig and module descriptionAxel Lin2014-04-16
| | | | | | | | | Signed-off-by: Axel Lin <axel.lin@ingics.com> Acked-by: Robin Gong <b38343@freescale.com> Signed-off-by: Mark Brown <broonie@linaro.org> (cherry picked from commit 2cee2121db44cfeee206d0854bedd52344eea444) Signed-off-by: Robin Gong <b38343@freescale.com>
* regulator: pfuze100: Add terminate entry for [i2c|of]_device_id tablesAxel Lin2014-04-16
| | | | | | | | | | | | | | Also remove PFUZE_NUM to avoid below build warnings: CC [M] drivers/regulator/pfuze100-regulator.o drivers/regulator/pfuze100-regulator.c:86:2: warning: excess elements in array initializer [enabled by default] drivers/regulator/pfuze100-regulator.c:86:2: warning: (near initialization for 'pfuze_device_id') [enabled by default] drivers/regulator/pfuze100-regulator.c:93:2: warning: excess elements in array initializer [enabled by default] drivers/regulator/pfuze100-regulator.c:93:2: warning: (near initialization for 'pfuze_dt_ids') [enabled by default] Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@linaro.org> (cherry picked from commit e6c4c3378d82c5eeb136ed06b1a23651bcdaf739)
* regulator: pfuze100: add pfuze200 supportRobin Gong2014-04-16
| | | | | | | | | | | | support pfuze200 chip which remove SW1C and SW4 based on pfuze100. Signed-off-by: Robin Gong <b38343@freescale.com> Signed-off-by: Mark Brown <broonie@linaro.org> (cherry picked from commit f2518480c7b744296a5587990a54e3a284d932b8) Conflicts: drivers/regulator/pfuze100-regulator.c
* regulator: pfuze100: Fix address of FABIDAxel Lin2014-04-16
| | | | | | | | | | 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 (cherry picked from commit c07a24939f36fb6de522a9726369ea64eee5d98d)
* ENGR00276832-1 pmic: max17135: port driver codes to 3.10 kernelRobby Cai2014-04-16
| | | | | | | | | | It's ported from v3.5.7 kernel, which contains a sensor driver and regulator driver. It's used for E-Ink panel. add a parameter for mfd_add_devices() due to the propotype change. use IS_ERR() to check the return value for devm_regulator_get(). Signed-off-by: Robby Cai <R63905@freescale.com>
* ENGR00274473-2 regulator: anatop: implement more callbackAnson Huang2014-04-16
| | | | | | | | | | | | Need to support anatop PU regulator on/off dynamically, so we need to add enable/disable/is_enabled/enable_time for anatop regulator. Only PU regulator in anatop can support dynamical on/off, so this implement is only for PU regulator, other regulators are always on. Signed-off-by: Anson Huang <b20788@freescale.com>
* ENGR00274473-1 regulator: add more notifier eventsAnson Huang2014-04-16
| | | | | | | | | | | | | | | Some hardware modules need strict flows according to regulator's enable/disable, such as for i.MX6 SOC's PU regulator, there is another power gate in GPC module, it needs to disable PU modules' clock before PU regulator is disabled and need to enable clock right after PU regulator is enabled, then it can do GPC's power gate operation. So we need to add REGULATOR_EVENT_PRE_DISABLE and REGULATOR_EVENT_ENABLE for regulator's notifier events. Signed-off-by: Anson Huang <b20788@freescale.com>
* regulator: pfuze100: Fix off-by-one for max_register settingAxel Lin2014-04-16
| | | | | | | | max_register should be register count - 1. Signed-off-by: Axel Lin <axel.lin@ingics.com> Reviewed-by: Robin Gong <b38343@freescale.com> Signed-off-by: Mark Brown <broonie@linaro.org>
* regulator: pfuze100: Simplify pfuze100_set_ramp_delay implementationAxel Lin2014-04-16
| | | | | | | | | | | | | | | | | Simplify the equation to calculate ramp_delay. Below equations are equivalent: ramp_delay = 25000 / (2 * ramp_delay); ramp_delay = 50000 / (4 * ramp_delay); ramp_delay = 25000 / (2 * ramp_delay); ramp_delay = 12500 / ramp_delay; So we don't need to read BIT6 of rdev->desc->vsel_reg for applying different equations. Also use rdev->desc->vsel_reg instead of run-time calculate register address. Signed-off-by: Axel Lin <axel.lin@ingics.com> Reviewed-by: Robin Gong <b38343@freescale.com> Signed-off-by: Mark Brown <broonie@linaro.org>
* regulator: pfuze100: Fix n_voltages setting for SW2~SW4 with high bit setAxel Lin2014-04-16
| | | | | | | | | | | | | | | | | | | | Current code adjust min_uV and uV_step but missed adjusting the n_voltages setting. When BIT6 is clear: n_voltages = (1975000 - 400000) / 25000 + 1 = 64 When BIT6 is set: n_voltages = (3300000 - 800000) / 50000 + 1 = 51 The n_voltages needs update because when BIT6 is set 0x73 ~ 0x7f are reserved. When using regulator_list_voltage_linear, the n_voltages does matter here because wrong n_voltages setting make the equation return wrong result. e.g. if selector is 63, regulator_list_voltage_linear returns 800000 + (50000 * 63) = 4000000 It should return -EINVAL if the selector is in the range of 51 ~ 63. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@linaro.org>
* regulator: pfuze100: Use regulator_map_voltage_ascendAxel Lin2014-04-16
| | | | | | | | All table based voltage list have ascendant order. Use regulator_map_voltage_ascend for them. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@linaro.org>
* regulator: pfuze100: Fix module alias prefixAxel Lin2014-04-16
| | | | | | | i2c drivers use "i2c:" prefix for module alias. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@linaro.org>
* regulator: pfuze100: Use i2c_[set|get]_clientdataAxel Lin2014-04-16
| | | | | | | | Since this is a i2c driver, use i2c_[set|get]_clientdata instead of dev_[set|get]_drvdata. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@linaro.org>
* regulator: pfuze100: REGULATOR_PFUZE100 needs to select REGMAP_I2CAxel Lin2014-04-16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | This fixes below build errors: CC [M] drivers/regulator/pfuze100-regulator.o drivers/regulator/pfuze100-regulator.c:342:21: error: variable 'pfuze_regmap_config' has initializer but incomplete type drivers/regulator/pfuze100-regulator.c:343:2: error: unknown field 'reg_bits' specified in initializer drivers/regulator/pfuze100-regulator.c:343:2: warning: excess elements in struct initializer [enabled by default] drivers/regulator/pfuze100-regulator.c:343:2: warning: (near initialization for 'pfuze_regmap_config') [enabled by default] drivers/regulator/pfuze100-regulator.c:344:2: error: unknown field 'val_bits' specified in initializer drivers/regulator/pfuze100-regulator.c:344:2: warning: excess elements in struct initializer [enabled by default] drivers/regulator/pfuze100-regulator.c:344:2: warning: (near initialization for 'pfuze_regmap_config') [enabled by default] drivers/regulator/pfuze100-regulator.c:345:2: error: unknown field 'max_register' specified in initializer drivers/regulator/pfuze100-regulator.c:345:2: warning: excess elements in struct initializer [enabled by default] drivers/regulator/pfuze100-regulator.c:345:2: warning: (near initialization for 'pfuze_regmap_config') [enabled by default] drivers/regulator/pfuze100-regulator.c:346:2: error: unknown field 'cache_type' specified in initializer drivers/regulator/pfuze100-regulator.c:346:2: warning: excess elements in struct initializer [enabled by default] drivers/regulator/pfuze100-regulator.c:346:2: warning: (near initialization for 'pfuze_regmap_config') [enabled by default] drivers/regulator/pfuze100-regulator.c: In function 'pfuze100_regulator_probe': drivers/regulator/pfuze100-regulator.c:370:2: error: implicit declaration of function 'devm_regmap_init_i2c' [-Werror=implicit-function-declaration] drivers/regulator/pfuze100-regulator.c:370:21: warning: assignment makes pointer from integer without a cast [enabled by default] cc1: some warnings being treated as errors make[2]: *** [drivers/regulator/pfuze100-regulator.o] Error 1 make[1]: *** [drivers/regulator] Error 2 make: *** [drivers] Error 2 Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@linaro.org>
* regulator: pfuze100: add MODULE_LICENSE() in pfuze100 driverRobin Gong2014-04-16
| | | | | | | | | Fix building error on x86_64 and i386: WARNING: modpost: missing MODULE_LICENSE() in drivers/regulator/pfuze100-regulator.o Signed-off-by: Robin Gong <b38343@freescale.com> Signed-off-by: Mark Brown <broonie@linaro.org>
* regulator:pfuze100: fix build warning and correct the binding docRobin Gong2014-04-16
| | | | | | | fix building warning and correct the binding doc Signed-off-by: Robin Gong <b38343@freescale.com> Signed-off-by: Mark Brown <broonie@linaro.org>
* regulator: pfuze100: add pfuze100 regulator driverRobin Gong2014-04-16
| | | | | | | | Add pfuze100 regulator driver. Signed-off-by: Robin Gong <b38343@freescale.com> Tested-by: Steffen Trumtrar <s.trumtrar@pengutronix.de> Signed-off-by: Mark Brown <broonie@linaro.org>
* mfd: tps6586x: correct device name of the regulator cellMarc Dietrich2013-06-24
| | | | | | | | 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: Marc Dietrich <marvin24@gmx.de> Signed-off-by: Mark Brown <broonie@linaro.org>
* Merge remote-tracking branch 'regulator/fix/palmas' into regulator-linusMark Brown2013-05-30
|\
| * regulator: palmas: Fix "enable_reg" to point to the correct reg for SMPS10Kishon Vijay Abraham I2013-05-30
| | | | | | | | | | | | | | | | | | | | | | regulator_enable_regmap() uses enable_reg to enable the regulator. But enable_reg for smps10 points to SMPS10_STATUS which is a read-only register. Fixed the same by having enable_reg set to SMPS10_CTRL. Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Cc: stable@vger.kernel.org
| * regulator: palmas: Fix incorrect conditionSachin Kamat2013-05-30
| | | | | | | | | | | | | | | | | | | | | | Since 'id' cannot take two values at the same time, the condition should probably be an OR (||) instead of AND (&&). Introduced by commit 28d1e8cd67 ("regulator: palma: add ramp delay support through regulator constraints"). Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | Merge remote-tracking branch 'regulator/fix/doc' into regulator-linusMark Brown2013-05-30
|\ \
| * | regulator: Fix kernel-doc generation warnings.Robert P. J. Day2013-05-02
| | | | | | | | | | | | | | | | | | | | | | | | Add a couple kernel-doc lines to get rid of kernel-doc generation warnings, no functional change. Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | | Merge remote-tracking branch 'regulator/fix/dbx500' into regulator-linusMark Brown2013-05-30
|\ \ \
| * | | regulator: dbx500: Make local symbol staticSachin Kamat2013-05-08
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | power_state_active_get is used only in this file. Make it static. While at it also move this function definition inside the CONFIG_REGULATOR_DEBUG macro as it is called only from within it. This also avoids further build warning related to unused definition. Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | | | regulator: core: Correct spelling mistake in commentCharles Keepax2013-05-21
| |_|/ |/| | | | | | | | | | | Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | | Merge tag 'gpio-for-linus' of git://git.secretlab.ca/git/linuxLinus Torvalds2013-05-09
|\ \ \ | |_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Pull removal of GENERIC_GPIO from Grant Likely: "GENERIC_GPIO now synonymous with GPIOLIB. There are no longer any valid cases for enableing GENERIC_GPIO without GPIOLIB, even though it is possible to do so which has been causing confusion and breakage. This branch does the work to completely eliminate GENERIC_GPIO." * tag 'gpio-for-linus' of git://git.secretlab.ca/git/linux: gpio: update gpio Chinese documentation Remove GENERIC_GPIO config option Convert selectors of GENERIC_GPIO to GPIOLIB blackfin: force use of gpiolib m68k: coldfire: use gpiolib mips: pnx833x: remove requirement for GENERIC_GPIO openrisc: default GENERIC_GPIO to false avr32: default GENERIC_GPIO to false xtensa: remove explicit selection of GENERIC_GPIO sh: replace CONFIG_GENERIC_GPIO by CONFIG_GPIOLIB powerpc: remove redundant GENERIC_GPIO selection unicore32: default GENERIC_GPIO to false unicore32: remove unneeded select GENERIC_GPIO arm: plat-orion: use GPIO driver on CONFIG_GPIOLIB arm: remove redundant GENERIC_GPIO selection mips: alchemy: require gpiolib mips: txx9: change GENERIC_GPIO to GPIOLIB mips: loongson: use GPIO driver on CONFIG_GPIOLIB mips: remove redundant GENERIC_GPIO select
| * | Convert selectors of GENERIC_GPIO to GPIOLIBAlexandre Courbot2013-04-16
| |/ | | | | | | | | | | | | | | | | GENERIC_GPIO is now equivalent to GPIOLIB and features that depended on GENERIC_GPIO can now depend on GPIOLIB to allow removal of this option. Signed-off-by: Alexandre Courbot <acourbot@nvidia.com> Acked-by: Linus Walleij <linus.walleij@linaro.org> Acked-by: Grant Likely <grant.likely@secretlab.ca>
* | Merge remote-tracking branch 'regulator/topic/wm8994' into v3.9-rc8Mark Brown2013-04-27
|\ \
| * | regulator: wm8994: Use GPIO parsed from DT when registering regulatorsSylwester Nawrocki2013-04-11
| | | | | | | | | | | | | | | | | | | | | | | | Ensure the regulators are registered with a GPIO parsed from the device tree when available. Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| * | regulator: wm8994: Provide default init dataMark Brown2013-04-07
| | | | | | | | | | | | | | | | | | | | | | | | | | | Almost all systems use the regulators on the WM8994 series devices to provide DCVDD and AVDD1 so if no init data is supplied then set up the supplies for the user. This simplifies integration of the device into systems, especially when device tree is supported. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| * | regulator: wm8994: Convert to module_platform_driver()Mark Brown2013-04-05
| |/ | | | | | | | | | | | | The regulators can only be used to supply the CODEC so we don't need to worry about users that still need fudges for init ordering issues. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | Merge remote-tracking branch 'regulator/topic/twl' into v3.9-rc8Mark Brown2013-04-27
|\ \
| * | regulator: twl: Remove TWL6030_FIXED_RESOURCEAxel Lin2013-03-01
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | TWL6030_FIXED_RESOURCE is not used now, remove it. TWL6030_FIXED_RESOURCE is not used since commit e76ab829cc "regulator: twl: Remove references to the twl4030 regulator" twl6030_fixed_resource is removed by commit 029dd3cef "regulator: twl: Remove another unused variable warning". Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| * | regulator: twl: Remove VDD1_VSEL_table and VDD2_VSEL_tableAxel Lin2013-03-01
| | | | | | | | | | | | | | | | | | | | | | | | Since commit ba305e31 "regulator: twl: fix twl4030 support for smps regulators", VDD1_VSEL_table and VDD2_VSEL_table are not used any more. Remove them. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| * | regulator: twl: Convert twl[6030|4030]fixed_ops to regulator_list_voltage_linearAxel Lin2013-03-01
| | | | | | | | | | | | | | | Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | | Merge remote-tracking branch 'regulator/topic/tps80031' into v3.9-rc8Mark Brown2013-04-27
|\ \ \
| * | | regulator: tps80031: Convert tps80031_dcdc_ops to [get|set]_voltage_sel_regmapAxel Lin2013-04-23
| | | | | | | | | | | | | | | | | | | | Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| * | | regulator: tps80031: Fix LDO2 track mode for TPS80031 or TPS80032-ES1.0Axel Lin2013-04-23
| | |/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently we have a special code in tps80031_ldo_set_voltage_sel() to handle LDO2 track mode for TPS80031 or TPS80032-ES1.0. The purpose is to address below issues: Issue description: - LDO2 traking mode is enabled - LDO2 tracks SMPS2 voltage. - LDO2 automatically switch-off when LDO2_CFG_VOLTAGE is changed to some discrete values (non exhaustive list): 00011001, 00011010, 00011011, 00011100, . - LDO2 switch-on again when LDO2_CFG_VOLTAGE is changed to other values (non exhaustive list): 00011000, 00010111, . LDOs have reserved codes. For these codes, LDO is switch-off. In tracking, LDO2 ref comes from SMPS2. However LDO2 enable is still gated by LDO2 VSEL decoding. As a result, in tracking mode LDO2 will be disabled for following code (SMPS VSEL format): 000000 & 100000 (MSB not decoded) 011001 & 111001 (MSB not decoded) 011010 & 111010 (MSB not decoded) 011100 & 111100 (MSB not decoded) 011101 & 111101 (MSB not decoded) 011110 & 111110 (MSB not decoded) However, current code has below bugs: 1. It uses regulator_list_voltage_linear, so list_voltage() still shows above invalid selectors have supported voltage. 2. Current code may return -EINVAL in tps80031_ldo_set_voltage_sel() for supported voltage. This is because when we use regulator_list_voltage_linear as list_voltage callback, regulator core will default use regulator_map_voltage_linear(). regulator_map_voltage_linear() has an assumption that the voltages are linear which is not true for this case. For example, when request voltage range is: min_uV=950000 uV && max_uV=1200000 uV regulator_map_voltage_linear() returns the selector is 29 (0x1D), set_voltage_sel() returns -EINVAL. (The selector is in invalid range, 0x19 ~ 0x1f). In above case, map_voltage() should find the lowest valid voltage within specific range (selector = 0x20) and set_voltage_sel() should successfully set the voltage to 987500 uV. This patch fixes these issues by: 1. Add checking valid setting for LDO2 track mode of TPS80031 or TPS80032-ES1.0 in list_voltage. So it returns -EINVAL for invalid selectors. 2. Implement tps80031_ldo_map_voltage, use regulator_map_voltage_iterate() to find the lowest voltage within specific range for TPS80031 or TPS80032-ES1.0. This is required when the voltage map is no longer linear. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | | Merge remote-tracking branch 'regulator/topic/tps6586x' into v3.9-rc8Mark Brown2013-04-27
|\ \ \
| * | | regulator: tps6586x: Use dev_err rather than dev_warn for error messageAxel Lin2013-03-03
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | tps6586x_regulator_set_slew_rate() returns -EINVAL when having slew rate settings for other than SM0/1, thus use dev_err rather than dev_warn. Signed-off-by: Axel Lin <axel.lin@ingics.com> Reviewed-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| * | | regulator: tps6586x: (cosmetic) simplify a conditionalGuennadi Liakhovetski2013-03-03
| | |/ | |/| | | | | | | | | | | | | | | | | | | of_node_put() is called on either branch of a conditional, simplify the code by only calling it once. Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | | Merge remote-tracking branch 'regulator/topic/tps65023' into v3.9-rc8Mark Brown2013-04-27
|\ \ \
| * | | regulator: tps65023: Use [set|get]_voltage_sel_regmap instead of open codedAxel Lin2013-04-23
| | |/ | |/| | | | | | | | | | | | | | | | | | | Simply the [get|set]_voltage_sel implementation by using regulator_[set|get]_voltage_sel_regmap instead of open coded. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | | Merge remote-tracking branch 'regulator/topic/tps62360' into v3.9-rc8Mark Brown2013-04-27
|\ \ \
| * | | regulator: tps62360: Fix off-by-one shift for ramp_ctrlAxel Lin2013-04-23
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | According to the datasheet[1] Register 0x06h Description: RmpCtrl (REGISTER ADDRESS: 0x06h Read/Write) BIT[5..7]: RMP[2:0] Output voltage ramp timing D7-D5 Slope 000 32mV/us 001 16mV/us 010 8mV/us ... 110 0.5mV/us 111 0.25mV/us Thus to get correct ramp_ctrl value, we need to right-shift 5 bits. [1] http://www.ti.com/lit/ds/symlink/tps62360.pdf Signed-off-by: Axel Lin <axel.lin@ingics.com> Acked-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | | Merge remote-tracking branch 'regulator/topic/s5m8767' into v3.9-rc8Mark Brown2013-04-27
|\ \ \