summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Merge remote-tracking branch 'regulator/topic/of' into regulator-nextMark Brown2013-02-198-19/+30
|\
| * regulator: mc13xxx: Use of_get_child_count()Axel Lin2013-01-311-5/+3
| | | | | | | | | | Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| * regulator: max8997: Use of_get_child_count()Axel Lin2013-01-311-3/+1
| | | | | | | | | | Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| * regulator: Add missing of_node_put()Axel Lin2013-01-308-11/+26
| | | | | | | | | | | | | | | | | | | | | | | | of_find_node_by_name() returns a node pointer with refcount incremented, use of_node_put() on it when done. of_find_node_by_name() will call of_node_put() against from parameter, thus we also need to call of_node_get(from) before calling of_find_node_by_name(). Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| *---. Merge remote-tracking branches 'regulator/fix/max8907', ↵Mark Brown2013-01-305-43/+123
| |\ \ \ | | | | | | | | | | | | | | | 'regulator/fix/max8997', 'regulator/fix/tps65910' and 'regulator/topic/mc13892' into regulator-of
* | \ \ \ Merge remote-tracking branch 'regulator/topic/mc13892' into regulator-nextMark Brown2013-02-193-22/+103
|\ \ \ \ \ | | |_|_|/ | |/| | |
| * | | | regulator: mc13892: sanity check num_regulators parsed vs. registeredMatt Sealey2013-01-273-6/+47
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Imagine a situation where a device tree has a few regulators in an appropriate node: regulators { sw1 { .. }; vvideo { .. }; : vfake { .. }; vtypo { .. }; }; In the above example, the node name "vfake" is an attempt to match a regulator name inside the driver which just so happens to not exist. The node name "vtypo" represents an accidental typographical error in a regulator name which may have been introduced to a device tree. In these cases, the number of regulators the mc13892 driver thinks it has does not match the number of regulators it parsed and registered. Since it will go over this array based on this number, it will actually re-register regulator "0" (which happens to be SW1) over and over again until it reaches the number, resulting in messages on the kernel log such as these: SW1: at 1100 mV VVIDEO: at 2775mV : SW1: at 1100 mV SW1: at 1100 mV .. up to that number of "mismatched" regulators. Nobody using DT can/will consume these regulators, so it should not be possible for it to cause any real regulator problems or driver breakages, but it is an easy thing to miss in a kernel log and is an immediate indication of a problem with the device tree authoring. This patch effectively sanity checks the number of counted children of the regulators node vs. the number that actually matched driver names, and sets the appropriate num_regulators value. It also gives a little warning for device tree authors that they MAY have screwed something up, such that this patch does not hide the device tree authoring problem. Signed-off-by: Matt Sealey <matt@genesi-usa.com> Tested-by: Steev Klimaszewski <steev@genesi-usa.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| * | | | regulator: mc13892-regulator: correct/refine handling of the SWxHI bitMatt Sealey2013-01-271-16/+56
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | MC13892 PMIC supports a "HI" bit for 3 of it's 4 buck switcher outputs, which enables a higher set of voltage ranges. Despite a comment in the code ('sw regulators need special care due to the "hi" bit'), it actually does not take special care since it does not modify it's use of the selector table index when this bit is set, giving us very odd behavior when setting a high voltage on supported switchers or listing current voltages. Net effect is in best case the kernel and sysfs report lower voltages than are actually set in hardware (1300mV instead of 1800mV for example) and in the worst case setting a voltage (e.g. 1800mV) will cause an undervoltage condition (e.g. 1300mV). Correct the behavior, taking into account SW1 doesn't support the HI bit, and as such we need to ignore it. While we are modifying these functions, fix and optimize the following; * set_voltage_sel callback was using .reg instead of .vsel_reg - since they were set to the same value it actually didn't break anything but it would be semantically incorrect to use .reg in this case. We now use .vsel_reg and be consistent. * vsel_shift is always 0 for every SWx regulator, and constantly shifting and masking off the bottom few bits is time consuming and makes the code very hard to read - optimize this out. * get_voltage_sel uses the variable "val" and set_voltage_sel uses the variable "selector" (and reg_value). Introduce the variable "selector" to get_voltage_sel such that it makes more sense and allow some leaner code in light of the modifications in this patch. Add better exposure to the debug print so the register value AND the selector are printed as this will adequately show the HI bit in the register. * correct a comment in probe which is doing a version check. Magic values are awful but for once instance, a comment does just as good a job as something symbolic. Signed-off-by: Matt Sealey <matt@genesi-usa.com> Tested-by: Steev Klimaszewski <steev@genesi-usa.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | | | | Merge remote-tracking branch 'regulator/topic/max8998' into regulator-nextMark Brown2013-02-191-13/+1
|\ \ \ \ \
| * | | | | regulator: max8998: Let regulator core handle the case selector == old_selectorAxel Lin2013-02-081-13/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | | | | | Merge remote-tracking branch 'regulator/topic/max8997' into regulator-nextMark Brown2013-02-191-61/+20
|\ \ \ \ \ \
| * | | | | | regulator: max8997: Convert max8997_safeout_ops to set_voltage_sel and ↵Axel Lin2012-12-271-58/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | list_voltage_table Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| * | | | | | regulator: max8997: Remove set_voltage_time_sel setting for max8997_ldo_opsAxel Lin2012-12-271-3/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | max8997_set_voltage_ldobuck_time_sel() returns 0 for all LDOs. Thus remove set_voltage_time_sel setting for max8997_ldo_ops. max8997_set_voltage_ldobuck_time_sel() is only used for max8997_buck_ops now, rename it to max8997_set_voltage_buck_time_sel(). Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | | | | | | Merge remote-tracking branch 'regulator/topic/max77686' into regulator-nextMark Brown2013-02-191-6/+8
|\ \ \ \ \ \ \
| * | | | | | | regulator: max77686: Reuse rdev_get_id() function.Thiago Farina2013-02-141-6/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Thiago Farina <tfarina@chromium.org> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | | | | | | | Merge remote-tracking branch 'regulator/topic/lp8788' into regulator-nextMark Brown2013-02-192-128/+46
|\ \ \ \ \ \ \ \
| * | | | | | | | regulator: lp8788-buck: Remove buck[1|2]_vout_addr arrayAxel Lin2013-01-171-12/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The vout address for buck[1|2] can be easily calculated, thus remote these arrays. Signed-off-by: Axel Lin <axel.lin@ingics.com> Acked-by: Milo Kim <milo.kim@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| * | | | | | | | regulator: lp8788-buck: Silence build warningAxel Lin2013-01-101-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This driver use id as array index, thus add bounder checking for id. This patch fixes below build warning: drivers/regulator/lp8788-buck.c: In function 'lp8788_buck_probe': drivers/regulator/lp8788-buck.c:490:8: warning: array subscript is above array bounds [-Warray-bounds] drivers/regulator/lp8788-buck.c:489:63: warning: array subscript is above array bounds [-Warray-bounds] Reported-by: Fengguang Wu <fengguang.wu@intel.com> Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| * | | | | | | | regulator: lp8788-ldo: Use ldo->en_pin to check if regulator is enabled by ↵Axel Lin2013-01-071-93/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | external pin ldo->en_pin is set iff the regulator is enabled by external pin. This patch sets ldo->en_pin to NULL if lp8788_gpio_request_ldo_en() fails, then we can use it to determinate if the regulator is controlled by external pin or register. lp8788_get_ldo_enable_mode(), lp8788_ldo_ctrl_by_extern_pin() and lp8788_ldo_is_enabled_by_extern_pin() functions are not used now, remove them. Signed-off-by: Axel Lin <axel.lin@ingics.com> Acked-by: Milo Kim <milo.kim@ti.com> Tested-by: Milo Kim <milo.kim@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| * | | | | | | | lp8788-ldo: fix a parent device on devm_gpio_request()Kim, Milo2013-01-031-6/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Use 'platform_device' rather than i2c client device node. Argument is added in lp8788_config_ldo_enable_mode(). Signed-off-by: Milo(Woogyom) Kim <milo.kim@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| * | | | | | | | lp8788-ldo: fix a parent device in _probe()Kim, Milo2013-01-031-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The lp8788-ldo is a platform driver of lp8788-mfd. The platform device is allocated when mfd_add_devices() is called in lp8788-mfd. On the other hand, 'lp->dev' is the i2c client device. Therefore, this 'platform_device' is a proper parent device in case of resource managed mem alloc, registering regulators and device kernel messages. Signed-off-by: Milo(Woogyom) Kim <milo.kim@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| * | | | | | | | lp8788-buck: fix a for-loop coding styleKim, Milo2013-01-031-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove space before semicolon in for-loop. Signed-off-by: Milo(Woogyom) Kim <milo.kim@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| * | | | | | | | lp8788-buck: fix a parent device on devm_gpio_request()Kim, Milo2013-01-031-6/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Use 'platform_device' rather than i2c client device node. Arguments are added in lp8788_init_dvs() and lp8788_dvs_gpio_request(). Signed-off-by: Milo(Woogyom) Kim <milo.kim@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| * | | | | | | | lp8788-buck: fix a parent deivce in _probe()Kim, Milo2013-01-031-3/+3
| | |/ / / / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The lp8788-buck is a platform driver of lp8788-mfd. The platform device is allocated when mfd_add_devices() is called in lp8788-mfd. On the other hand, 'lp->dev' is the i2c client device. Therefore, this 'platform_device' is a proper parent device in case of resource managed mem alloc, registering a regulator and device kernel message. Signed-off-by: Milo(Woogyom) Kim <milo.kim@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | | | | | | | Merge remote-tracking branch 'regulator/topic/lp8755' into regulator-nextMark Brown2013-02-194-0/+647
|\ \ \ \ \ \ \ \
| * | | | | | | | regulator: lp8755: Use LP8755_BUCK_MAX instead of magic numberAxel Lin2013-01-271-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| * | | | | | | | regulator: lp8755: Remove enum bucksAxel Lin2013-01-171-33/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We already have enum lp8755_bucks in lp8755.h, so it looks pointless adding enum bucks in lp8755.c. Signed-off-by: Axel Lin <axel.lin@ingics.com> Tested-by: Daniel Jeong <gshark.jeong@gmail.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| * | | | | | | | regulator: lp8755: Don't show unrelated messags in lp8755_probe error pathsAxel Lin2013-01-171-9/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| * | | | | | | | regulator: lp8755: Fix mask for pchip->mphaseAxel Lin2013-01-081-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | According to the datasheet, it has 9 multi-phase mode from 0 to 8 and it takes 4 bits in the register. The mask for pchip->mphase should be 0x0F. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| * | | | | | | | regulator: lp8755: Fix lp8755_regulator_init unwind codeAxel Lin2013-01-081-4/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It's safe to pass NULL argument to regulator_unregister(), so we can remove the NULL checking before calling regulator_unregister(). However pass a ERR_PTR to regulator_unregister() is wrong, so we need to explicitly set "pchip->rdev[buck_num] = NULL" before goto err_buck. This patch also includes below cleanups: Show correct regulator id in dev_err. Remove __devexit_p. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| * | | | | | | | regulator: lp8755: new driver for LP8755Daniel Jeong2012-12-244-0/+661
| |/ / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch is for new lp8755 regulator dirver and several unsed variables were deleted and then test was done. LP8755 : The LP8755 is a high performance power management unit.It contains six step-down DC-DC converters which can can be filexibly bundled together in multiphase converters as required by application. www.ti.com Signed-off-by: Daniel Jeong <gshark.jeong@gmail.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | | | | | | | Merge remote-tracking branch 'regulator/topic/lp872x' into regulator-nextMark Brown2013-02-191-29/+7
|\ \ \ \ \ \ \ \
| * | | | | | | | regulator: lp872x: Kill _rdev_to_offset() functionAxel Lin2012-12-101-29/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There is only one user calling _rdev_to_offset() function. Remove _rdev_to_offset() makes the code simpler. Signed-off-by: Axel Lin <axel.lin@ingics.com> Acked-by: Milo(Woogyom) Kim <milo.kim@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | | | | | | | | Merge remote-tracking branch 'regulator/topic/lp3972' into regulator-nextMark Brown2013-02-191-16/+6
|\ \ \ \ \ \ \ \ \
| * | | | | | | | | regulator: lp3972: Convert to get_voltage_selAxel Lin2013-01-081-16/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | regulator_list_voltage_table() returns -EINVAL if selector >= n_voltages. Thus we don't need to check if reg is greater than LP3972_BUCK_VOL_MAX_IDX in lp3972_[ldo|dcdc]_get_voltage_sel. LP3972_BUCK_VOL_MIN_IDX and LP3972_BUCK_VOL_MAX_IDX are not used, remove them. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | | | | | | | | | Merge remote-tracking branch 'regulator/topic/lp3971' into regulator-nextMark Brown2013-02-191-16/+6
|\ \ \ \ \ \ \ \ \ \
| * | | | | | | | | | regulator: lp3971: Convert to get_voltage_selAxel Lin2012-12-241-16/+6
| | |_|/ / / / / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | regulator_list_voltage_table() returns -EINVAL if selector >= n_voltages. Thus we don't need to check if reg is greater than BUCK_TARGET_VOL_MAX_IDX in lp3971_dcdc_get_voltage_sel. BUCK_TARGET_VOL_MIN_IDX and BUCK_TARGET_VOL_MAX_IDX are not used, remove them. Signed-off-by: Axel Lin <axel.lin@ingics.com> Acked-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | | | | | | | | | Merge remote-tracking branch 'regulator/topic/gpio' into regulator-nextMark Brown2013-02-192-6/+3
|\ \ \ \ \ \ \ \ \ \
| * | | | | | | | | | regulator: show state for GPIO-controlled regulatorsMichał Mirosław2013-02-041-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Michał Mirosław <mirq-linux@rere.qmqm.pl> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| * | | | | | | | | | regulator: gpio-regulator: Staticize of_get_gpio_regulator_config()Axel Lin2013-01-291-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | of_get_gpio_regulator_config() is only used in gpio-regulator.c, make it static. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| * | | | | | | | | | regulator: gpio-regulator: Use of_gpio_count()Axel Lin2013-01-291-4/+1
| | |_|_|_|_|/ / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | | | | | | | | | Merge remote-tracking branch 'regulator/topic/da9055' into regulator-nextMark Brown2013-02-191-3/+0
|\ \ \ \ \ \ \ \ \ \
| * | | | | | | | | | regulator: da9055: Remove unused v_shift field from struct da9055_volt_regAxel Lin2013-01-071-3/+0
| | |_|/ / / / / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | | | | | | | | | Merge remote-tracking branch 'regulator/topic/core' into regulator-nextMark Brown2013-02-191-7/+22
|\ \ \ \ \ \ \ \ \ \
| * | | | | | | | | | regulator: Fix memory garbage dev_err printout.Russ Dill2013-02-141-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | commit dd8004af: 'regulator: core: Log when a device causes a voltage constraint fail', tried to print out some information about the check consumer min/max uV fixup, however, it uses a garbage pointer left over from list_for_each_entry leading to boot messages in the form: '[ 2.079890] <RANDOM ASCII>: Restricting voltage, 3735899821-4294967295uV' Because it references regulator->dev, it could potentially read memory from anywhere causing a panic. This patch instead uses rdev and the updated min/max uV values. Signed-off-by: Russ Dill <Russ.Dill@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| * | | | | | | | | | Merge tag 'v3.8-rc7' into regulator-coreMark Brown2013-02-1411398-325551/+550618
| |\ \ \ \ \ \ \ \ \ \ | | | |_|_|_|/ / / / / | | |/| | | | | | | | | | | | | | | | | | | Linux 3.8-rc7
| * | | | | | | | | | regulator: core: Optimize _regulator_do_set_voltage if voltage does not changeAxel Lin2013-02-081-3/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Optimize _regulator_do_set_voltage() for the case selector is equal to old_selector. Since the voltage does not change, we don't need to call set_voltage_sel() and set_voltage_time_sel() in this case. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
| * | | | | | | | | | regulator: core: if voltage scaling fails, restore original voltage valuesPaolo Pisati2012-12-151-2/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Paolo Pisati <paolo.pisati@canonical.com> Tested-by: Robert Nelson <robertcnelson@gmail.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* | | | | | | | | | | Merge remote-tracking branch 'regulator/topic/as3711' into regulator-nextMark Brown2013-02-191-1/+1
|\ \ \ \ \ \ \ \ \ \ \
| * | | | | | | | | | | regulator: as3711: Fix checking if no platform initialization dataAxel Lin2013-02-131-1/+1
| | |/ / / / / / / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | To skip registering regulator if no platform initialization data, we should check reg_data rather than ri->desc.name. Signed-off-by: Axel Lin <axel.lin@ingics.com> Acked-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
OpenPOWER on IntegriCloud