- 26 3月, 2019 1 次提交
-
-
由 Axel Lin 提交于
According to the datasheet the latest seletor 11 1111b = 3.3 V. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
- 19 3月, 2019 1 次提交
-
-
由 Steve Twiss 提交于
During several error paths in the function regulator_set_voltage_unlocked() the value of 'ret' can take on negative error values. However, in calls that go through the 'goto out' statement, this return value is lost and return 0 is used instead, indicating a 'pass'. There are several cases where this function should legitimately return a fail instead of a pass: one such case includes constraints check during voltage selection in the call to regulator_check_voltage(), which can have -EINVAL for the case when an unsupported voltage is incorrectly requested. In that case, -22 is expected as the return value, not 0. Fixes: 9243a195 ("regulator: core: Change voltage setting path") Cc: stable <stable@vger.kernel.org> Signed-off-by: NSteve Twiss <stwiss.opensource@diasemi.com> Reviewed-by: NDmitry Osipenko <digetx@gmail.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
- 04 3月, 2019 12 次提交
-
-
由 Axel Lin 提交于
These regulator_ops variables should never change, make them const. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
The palmas_smps_ramp_delay array should never modify, make it const. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
Use regulator_set/get_current_limit_regmap helpers to save some code. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Acked-by: NCharles Keepax <ckeepax@opensource.cirrus.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
Use regulator_set/get_current_limit_regmap helpers to save some code. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Acked-by: Steve Twiss <stwiss.opensource@diasemi.com>; Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
Use regulator_set/get_current_limit_regmap helpers to save some code. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Acked-by: NSteve Twiss <stwiss.opensource@diasemi.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
Use regulator_set/get_current_limit_regmap helpers to save some code. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Acked-by: NSteve Twiss <stwiss.opensource@diasemi.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
Use regulator_set/get_current_limit_regmap helpers to save some code. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Acked-by: NBartosz Golaszewski <bgolaszewski@baylibre.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
Use regulator_set/get_current_limit_regmap helpers to save some code. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
Use regulator_set/get_current_limit_regmap helpers to save some code. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
Use regulator_set/get_current_limit_regmap helpers to save some code. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Acked-by: NSteve Twiss <stwiss.opensource@diasemi.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
Use regulator_set/get_current_limit_regmap helpers to save some code. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Acked-by: NSteve Twiss <stwiss.opensource@diasemi.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
By setting curr_table, n_current_limits, csel_reg and csel_mask, the regmap users can use regulator_set_current_limit_regmap and regulator_get_current_limit_regmap for set/get_current_limit callbacks. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
- 28 2月, 2019 1 次提交
-
-
由 Fabrice Gasnier 提交于
Add support for suspend/resume and runtime PM to stm32-vrefbuf driver. Signed-off-by: NFabrice Gasnier <fabrice.gasnier@st.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
- 27 2月, 2019 4 次提交
-
-
由 Axel Lin 提交于
The *i2c and *i2c_8606 are no longer used since this driver was converted to use regmap helpers. The *chip and *regulator are not really required. So remove these unused fields. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
Set volt_table filed then we can use regulator_list_voltage_table. Since we have volt_table setting, now we can remove vol_table from struct pm8607_regulator_info. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
They should never change, make them const. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Acked-by: NTony Lindgren <tony@atomide.com> Reviewed-by: NSebastian Reichel <sebastian.reichel@collabora.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
This driver uses regulator_get/set_voltage_sel_regmap so it does not use vsel_shift. Actually, vsel_shift can be calculated by vsel_mask setting. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Tested-by: NTony Lindgren <tony@atomide.com> Reviewed-by: NSebastian Reichel <sebastian.reichel@collabora.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
- 26 2月, 2019 5 次提交
-
-
由 Gustavo A. R. Silva 提交于
One of the more common cases of allocation size calculations is finding the size of a structure that has a zero-sized array at the end, along with memory for some number of elements for that array. For example: struct foo { int stuff; struct boo entry[]; }; size = sizeof(struct foo) + count * sizeof(struct boo); instance = alloc(size, GFP_KERNEL) Instead of leaving these open-coded and prone to type mistakes, we can now use the new struct_size() helper: instance = alloc(struct_size(instance, entry, count), GFP_KERNEL) Notice that, in this case, variable size is not necessary, hence it is removed. This code was detected with the help of Coccinelle. Signed-off-by: NGustavo A. R. Silva <gustavo@embeddedor.com> Acked-by: NSteve Twiss <stwiss.opensource@diasemi.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
The module version is unlikely to be updated, use kernel version should be enough. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Acked-by: NNicolas Ferre <nicolas.ferre@microchip.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
Current code does not really avoid array access out of bounds, fix it by add checking for pdata->slew_rate. If pdata->slew_rate is too big, it's a bug in pdata that needs fix. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
Setup .vsel_reg and .vsel_mask then we can use the standard set/get_voltage_sel_regmap helpers to simplify the code. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Acked-by: NCharles Keepax <ckeepax@opensource.cirrus.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
The wm831x_dcdc_ilim entries needs to be uA because it is used to compare with min_uA and max_uA. While at it also make the array const and change to use unsigned int. Fixes: e4ee831f ("regulator: Add WM831x DC-DC buck convertor support") Signed-off-by: NAxel Lin <axel.lin@ingics.com> Acked-by: NCharles Keepax <ckeepax@opensource.cirrus.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
- 22 2月, 2019 8 次提交
-
-
由 Gustavo A. R. Silva 提交于
One of the more common cases of allocation size calculations is finding the size of a structure that has a zero-sized array at the end, along with memory for some number of elements for that array. For example: struct foo { int stuff; struct boo entry[]; }; size = sizeof(struct foo) + count * sizeof(struct boo); instance = alloc(size, GFP_KERNEL) Instead of leaving these open-coded and prone to type mistakes, we can now use the new struct_size() helper: instance = alloc(struct_size(instance, entry, count), GFP_KERNEL) Notice that, in this case, variable size is not necessary, hence it is removed. This code was detected with the help of Coccinelle. Signed-off-by: NGustavo A. R. Silva <gustavo@embeddedor.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
Current code already set .min_uV and .uV_step fields and it actually can use regulator_list_voltage_linear. So remove buck_volt_range and use regulator_list_voltage_linear instead. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
Current code always return error, fix it. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Reviewed-by: NBartosz Golaszewski <bgolaszewski@baylibre.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Christian Hohnstaedt 提交于
Re-use the "tps65218_pmic_*_current_limit()" functions of LS3 and calculate the different required bit-shift by counting the trailing 0s in "struct regulator_desc.csel_mask" Signed-off-by: NChristian Hohnstaedt <Christian.Hohnstaedt@wago.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
Signed-off-by: NAxel Lin <axel.lin@ingics.com> Reviewed-by: NKrzysztof Kozlowski <krzk@kernel.org> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
The s5m8767_opmode_reg should never change, make it const. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Reviewed-by: NKrzysztof Kozlowski <krzk@kernel.org> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Marc Gonzalez 提交于
When REGULATOR_CHANGE_DRMS is not set, drms_uA_update is a no-op. It used to print a debug message, which was dropped in commit 8a34e979 ("regulator: refactor valid_ops_mask checking code") Let's bring the debug message back, because it helps find missing regulator-allow-set-load properties. Signed-off-by: NMarc Gonzalez <marc.w.gonzalez@free.fr> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
The lp873x_buck_ramp_delay should never change, make it const. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
- 21 2月, 2019 6 次提交
-
-
由 Bjorn Andersson 提交于
The FAN53526 differs from the FAN53555 only in that the mode bit in VSEL0/VSEL1 is moved to the CONTROL register, the voltage selector mask is extended by 1 bit and the step is different. So extend the existing fan53555 driver to support FAN53526 as well. Signed-off-by: NBjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
Use linear range to replace the twl6030ldo_list_voltage implementation. With this change, the min_mV is not used and can be removed from struct twlreg_info. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
Add missing .owner field in regulator_desc, which is used for refcounting. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
Add missing .owner field in regulator_desc, which is used for refcounting. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Christian Hohnstaedt 提交于
- Fix list of valid LS3 currents from mA to µA - Fix selection of min/max microAmps of LS3. Selecting one of the configured values as max value now really selects it instead of the next lower one Signed-off-by: NChristian Hohnstaedt <Christian.Hohnstaedt@wago.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
- 19 2月, 2019 2 次提交
-
-
由 Colin Ian King 提交于
Currently rdev is dereferenced when assigning desc before rdev is null checked, this is leading to static analysis warnings. However, rdev can never be null, so the null check is redundant and can be removed. Detected by CoverityScan, CID#1476031 ("Dereference before null check") Fixes: 77e3e3b1 ("regulator: axp20x: add software based soft_start for AXP209 LDO3") Signed-off-by: NColin Ian King <colin.king@canonical.com> Acked-by: NChen-Yu Tsai <wens@csie.org> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
Selecting the minimal value is only true for voltage regulators. For current regulators the maximum in the given range should be selected instead. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Acked-by: NSteve Twiss <stwiss.opensource@diasemi.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-