- 07 2月, 2019 1 次提交
-
-
由 Linus Walleij 提交于
Use devm_* managed device resources and create a local struct device *dev variable to simplify the code inside probe(). Tested-by: NMarek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org> Signed-off-by: NMark Brown <broonie@kernel.org>
-
- 06 2月, 2019 4 次提交
-
-
由 Linus Walleij 提交于
This pushes the handling of inversion semantics and open drain settings to the GPIO descriptor and gpiolib. All affected board files are also augmented. This is especially nice since we don't have to have any confusing flags passed around to the left and right littering the fixed and GPIO regulator drivers and the regulator core. It is all just very straight-forward: the core asks the GPIO line to be asserted or deasserted and gpiolib deals with the rest depending on how the platform is configured: if the line is active low, it deals with that, if the line is open drain, it deals with that too. Cc: Alexander Shiyan <shc_work@mail.ru> # i.MX boards user Cc: Haojian Zhuang <haojian.zhuang@gmail.com> # MMP2 maintainer Cc: Aaro Koskinen <aaro.koskinen@iki.fi> # OMAP1 maintainer Cc: Tony Lindgren <tony@atomide.com> # OMAP1,2,3 maintainer Cc: Mike Rapoport <rppt@linux.vnet.ibm.com> # EM-X270 maintainer Cc: Robert Jarzmik <robert.jarzmik@free.fr> # EZX maintainer Cc: Philipp Zabel <philipp.zabel@gmail.com> # Magician maintainer Cc: Petr Cvek <petr.cvek@tul.cz> # Magician Cc: Robert Jarzmik <robert.jarzmik@free.fr> # PXA Cc: Paul Parsons <lost.distance@yahoo.com> # hx4700 Cc: Daniel Mack <zonque@gmail.com> # Raumfeld maintainer Cc: Marc Zyngier <marc.zyngier@arm.com> # Zeus maintainer Cc: Geert Uytterhoeven <geert+renesas@glider.be> # SuperH pinctrl/GPIO maintainer Cc: Russell King <rmk+kernel@armlinux.org.uk> # SA1100 Tested-by: NMarek Szyprowski <m.szyprowski@samsung.com> Tested-by: Janusz Krzysztofik <jmkrzyszt@gmail.com> #OMAP1 Amstrad Delta Signed-off-by: NLinus Walleij <linus.walleij@linaro.org> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Linus Walleij 提交于
This converts the GPIO regulator driver to use decriptors only. We have to let go of the array gpio handling: the fetched descriptors are handled individually anyway, and the array retrieveal function does not make it possible to retrieve each GPIO descriptor with unique flags. Instead get them one by one. We request the "enable" GPIO separately as before, and make sure that this line is requested as nonexclusive since enable lines can be shared and the regulator core expects this. Most users of the GPIO regulator are using device tree. There are two boards in the kernel using the gpio regulator from a non-devicetree path: PXA hx4700 and magician. Make sure to switch these over to use descriptors as well. Cc: Philipp Zabel <p.zabel@pengutronix.de> # Magician Cc: Petr Cvek <petr.cvek@tul.cz> # Magician Cc: Robert Jarzmik <robert.jarzmik@free.fr> # PXA Cc: Paul Parsons <lost.distance@yahoo.com> # hx4700 Cc: Kevin Hilman <khilman@baylibre.com> # Meson Cc: Neil Armstrong <narmstrong@baylibre.com> # Meson Tested-by: NMarek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
It looks like linear range is suitable to describe the voltage table for rk805 buck1/2: selector 0 ~ 59: 0.7125V with uV_step = 12500 selector 60 ~ 62: 1.8V with uV_step = 200000 selector 63: 2.3V With this change, then rk805 buck1/2 can reuse rk808_reg_ops_ranges. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Tested-by: NOtavio Salvador <otavio@ossystems.com.br> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Charles Keepax 提交于
A comma has been accidentally used where a semi-colon was clearly intended, correct this typo. Signed-off-by: NCharles Keepax <ckeepax@opensource.cirrus.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
- 03 2月, 2019 1 次提交
-
-
由 Otavio Salvador 提交于
RK805 has the following voltage range for the BUCK1 and BUCK2 regulators: From 0.7125V to 1.45V in 12.5mV steps, 1.8V, 2V, 2.2V and 2.3V , which corresponds to the following values as per the RK805 datasheet: 000 000: 0.7125V 000 001: 0.725V …… 111 011: 1.45V 111 100: 1.8V 111 101: 2.0V 111 110: 2.2V 111 111: 2.3V This means that the voltage range is not linear and so RK805 can not reuse the same regulator_ops structure from RK808. Fix it by creating a list with the correct supported voltage values for RK805 BUCK1 and BUCK2 regulators. Tested on a rv1108-elgin-r1 board that now correctly reports a BUCK2 voltage of 2.2V instead of the unsupported value of 1.4875V. Fixes: c4e0d344 ("regulator: rk808: Add regulator driver for RK805") Signed-off-by: NOtavio Salvador <otavio@ossystems.com.br> Signed-off-by: NMark Brown <broonie@kernel.org>
-
- 30 1月, 2019 1 次提交
-
-
由 Axel Lin 提交于
This is a platform driver, no need to include linux/i2c.h. Include linux/of.h for of_match_ptr. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Reviewed-by: NBartosz Golaszewski <bgolaszewski@baylibre.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
- 29 1月, 2019 1 次提交
-
-
由 Bartosz Golaszewski 提交于
Add regulator support for max77650. We support all four variants of this PMIC including non-linear voltage table for max77651 SBB1 rail. Signed-off-by: NBartosz Golaszewski <bgolaszewski@baylibre.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
- 28 1月, 2019 16 次提交
-
-
由 Axel Lin 提交于
Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
This driver is using devm_regulator_register, so it's not necessary to store *rdev[3] in struct isl_pmic. Use a local variable instead. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
This driver also supports RK805 now. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
While at it, also fix indent for rk805_reg_ops and rk805_switch_ops. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
Fix below build error: drivers/regulator/mcp16502.c: In function ‘mcp16502_gpio_set_mode’: drivers/regulator/mcp16502.c:135:3: error: implicit declaration of function ‘gpiod_set_value’; did you mean ‘gpio_set_value’? [-Werror=implicit-function-declaration] gpiod_set_value(mcp->lpm, 0); ^~~~~~~~~~~~~~~ gpio_set_value drivers/regulator/mcp16502.c: In function ‘mcp16502_probe’: drivers/regulator/mcp16502.c:486:13: error: implicit declaration of function ‘devm_gpiod_get’; did you mean ‘devm_gpio_free’? [-Werror=implicit-function-declaration] mcp->lpm = devm_gpiod_get(dev, "lpm", GPIOD_OUT_LOW); ^~~~~~~~~~~~~~ devm_gpio_free drivers/regulator/mcp16502.c:486:40: error: ‘GPIOD_OUT_LOW’ undeclared (first use in this function); did you mean ‘GPIOF_INIT_LOW’? mcp->lpm = devm_gpiod_get(dev, "lpm", GPIOD_OUT_LOW); ^~~~~~~~~~~~~ GPIOF_INIT_LOW 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 提交于
Since devm_regmap_field_alloc can fail, add error checking for it. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
Since devm_regmap_field_alloc can fail, add error checking for it. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Vasily Khoruzhick 提交于
Looks like refactoring didn't go well and left ALDO2, DLDO2 and ELDO3 definitions broken for AXP803 - now they are using register address instead of mask. Fix it by using mask where necessary. Fixes: db4a555f ("regulator: axp20x: use defines for masks") Signed-off-by: NVasily Khoruzhick <anarsoul@gmail.com> Reviewed-by: NChen-Yu Tsai <wens@csie.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 提交于
Signed-off-by: NAxel Lin <axel.lin@ingics.com> 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 提交于
Signed-off-by: NAxel Lin <axel.lin@ingics.com> 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 提交于
Signed-off-by: NAxel Lin <axel.lin@ingics.com> 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 提交于
Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
- 25 1月, 2019 3 次提交
-
-
由 Axel Lin 提交于
Signed-off-by: NAxel Lin <axel.lin@ingics.com> 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 提交于
Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
- 23 1月, 2019 6 次提交
-
-
由 Axel Lin 提交于
The regulator_linear_range arrays and stpmic1_regulator_cfgs are only accessed by this driver and the values are never changed so make them static const. regulator_ops variables can also be const. Also clean up a few empty lines in regulator_linear_range array. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Matti Vaittinen 提交于
BD70528MWV is an ultra-low Iq general purpose single-chip power management IC for battery-powered portable devices. Add support for controlling 3 bucks and 3 LDOs present in ROHM BD70528. Signed-off-by: NMatti Vaittinen <matti.vaittinen@fi.rohmeurope.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Bjorn Andersson 提交于
In some scenarios the early stages of the boot chain has configured regulators to be in a required state, but the later stages has skipped to inform the RPM about it's requirements. But as the SMD RPM regulators are being initialized voltage change requests will be issued to align the voltage with the valid ranges. The RPM aggregates all parameters for the specific regulator, the voltage will be adjusted and the "enabled" state will be "off" - and the regulator is turned off. This patch addresses this problem by caching the requested enable state, voltage and load and send the parameters in a batch, depending on the enable state - effectively delaying the voltage request for disabled regulators. 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 of_device_get_match_data() to simplify the code a bit. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
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>
-
- 19 1月, 2019 1 次提交
-
-
由 Charles Keepax 提交于
Add the missing MODULE_DEVICE_TABLE and remove the comma from the separator on the end of the of_device_id array. Signed-off-by: NCharles Keepax <ckeepax@opensource.cirrus.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
- 14 1月, 2019 5 次提交
-
-
由 Axel Lin 提交于
The act8600_sudcdc_voltage_ranges setting does not match the datasheet. The problems in below entry: REGULATOR_LINEAR_RANGE(19000000, 191, 255, 400000), 1. The off-by-one min_sel causes wrong volatage calculation. The min_sel should be 192. 2. According to the datasheet[1] Table 7. (on page 43): The selector 248 (0b11111000) ~ 255 (0b11111111) are 41.400V. Also fix off-by-one for ACT8600_SUDCDC_VOLTAGE_NUM. [1] https://active-semi.com/wp-content/uploads/ACT8600_Datasheet.pdf Fixes: df3a950e ("regulator: act8865: Add act8600 support") Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
Use of_device_get_match_data() to simplify the code a bit. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
The modalias is set by the MODULE_DEVICE_TABLE, thus remove redundant MODULE_ALIAS. 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 提交于
Having instance specific copy of desc is enough to support multiple instance of pwm regulator. The regulator_ops is never changed so no need to copy it per instance, make pwm_regulator_voltage_table_ops and pwm_regulator_voltage_continuous_ops const to ensure they won't be changed. The pwm_regulator_desc is a template to be copied so also make it const. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
由 Axel Lin 提交于
The ctrl_regs field is not used at all, remove it. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-
- 10 1月, 2019 1 次提交
-
-
由 Bartosz Golaszewski 提交于
Provide a helper allowing to access regulator's regmap. Signed-off-by: NBartosz Golaszewski <bgolaszewski@baylibre.com> Signed-off-by: NMark Brown <broonie@kernel.org>
-