summaryrefslogtreecommitdiffstats
path: root/drivers/regulator/max14577.c
Commit message (Collapse)AuthorAgeFilesLines
* regulator/mfd: max14577: Export symbols for calculating charger currentKrzysztof Kozlowski2014-09-241-76/+4
| | | | | | | | | | | | | | | | | | This patch prepares for changing the max14577 charger driver to allow configuring battery-dependent settings from DTS. The patch moves from regulator driver to MFD core driver and exports: - function for calculating register value for charger's current; - table of limits for chargers (MAX14577, MAX77836). Previously they were used only by the max14577 regulator driver. In next patch the charger driver will use them as well. Exporting them will reduce unnecessary code duplication. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Acked-by: Mark Brown <broonie@linaro.org> Acked-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Lee Jones <lee.jones@linaro.org>
* regulator: max14577: Add support for MAX77836 regulatorsKrzysztof Kozlowski2014-04-231-35/+242
| | | | | | | | | | | | | | | Add support for MAX77836 chipset and its additional two LDO regulators. These LDO regulators are controlled by the PMIC block with additional regmap (different I2C slave address). The MAX77836 charger and safeout regulators are almost identical to MAX14577. The registers layout is the same, except values for charger's current. The patch adds simple mapping between device type and supported current by the charger regulator. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Reviewed-by: Mark Brown <broonie@linaro.org> Signed-off-by: Lee Jones <lee.jones@linaro.org>
*-. Merge remote-tracking branches 'regulator/topic/doc', ↵Mark Brown2014-03-261-7/+1
|\ \ | | | | | | | | | 'regulator/topic/enable', 'regulator/topic/fan53555', 'regulator/topic/fixed', 'regulator/topic/gpio', 'regulator/topic/lp3971', 'regulator/topic/lp872x' and 'regulator/topic/max14577' into regulator-next
| | * regulator: max14577: Remove unused state container definitionKrzysztof Kozlowski2014-02-031-7/+1
| |/ | | | | | | | | | | | | | | | | Remove the "struct max14577_regulator" because this is not used anywhere. It should be removed earlier along with changing the driver after review on the mailing lists. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Mark Brown <broonie@linaro.org>
* | regulator: max14577: Fix invalid return value on DT parse successKrzysztof Kozlowski2014-02-221-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | 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>
* | regulator: max14577: Add missing of_node_putKrzysztof Kozlowski2014-02-051-2/+3
|/ | | | | | | | 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>
* regulator: max14577: Add module alias to support module auto-loadingAxel Lin2013-12-231-0/+1
| | | | | Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@linaro.org>
* regulator: max14577: Add regulator driver for Maxim 14577Krzysztof Kozlowski2013-12-181-0/+272
MAX14577 chip is a multi-function device which includes MUIC, charger and voltage regulator. The driver is located in drivers/mfd. This patch adds regulator driver for MAX14577 chip. There are two regulators in this chip: 1. Safeout LDO with constant voltage output of 4.9V. It can be only enabled or disabled. 2. Current regulator for the charger. It provides current from 90mA up to 950mA. Driver supports Device Tree. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Signed-off-by: Mark Brown <broonie@linaro.org>
OpenPOWER on IntegriCloud