Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f790bd9c authored by Linus Torvalds's avatar Linus Torvalds
Browse files
Pull regulator updates from Mark Brown:
 "Quite a lot of work going on the core this release, mainly around
  system initialization, but a quiet release for drivers:

   - fixes for registration of multiple regulators on a PMIC from Javier
     Martinez Canillas and Jon Hunter.

   - cleanups to the regulator_get() code from Dmitry Torokhov

   - lots of constifcation of structs from Bhumika Goyal

   - support for Motorola CPCAP regulators from Tony Lindgren"

* tag 'regulator-v4.11' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator: (52 commits)
  regulator: core: Resolve supplies before disabling unused regulators
  regulator: Fix regulator_summary for deviceless consumers
  regulator: tps65086: Fix DT node referencing in of_parse_cb
  regulator: tps65086: Fix expected switch DT node names
  regulator: core: simplify _regulator_get()
  regulator: core: have regulator_dev_lookup() return ERR_PTR-encoded errors
  regulator: gpio: correct default type
  regulator: cpcap: Add basic regulator support
  regulator: core: fix typo in regulator_bulk_disable()
  regulator: core: optimize devm_regulator_bulk_get()
  regulator: core: simplify regulator_bulk_force_disable()
  regulator: core: have _regulator_get() accept get_type argument
  regulator: core: remove dead code in _regulator_get()
  regulator: rn5t618: constify regulator_ops structure
  regulator: rc5t583-regulator: constify regulator_ops structure
  regulator: pv88090-regulator: constify regulator_ops structure
  regulator: pv88080-regulator: constify regulator_ops structure
  regulator: pv88060-regulator: constify regulator_ops structure
  regulator: pfuze100-regulator: constify regulator_ops structure
  regulator: pcf50633-regulator: constify regulator_ops structure
  ...
parents b3de5ad6 fad9cd45
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -14,6 +14,7 @@ Optional properties:
- anatop-delay-bit-shift: Bit shift for the step time register
- anatop-delay-bit-width: Number of bits used in the step time register
- vin-supply: The supply for this regulator
- anatop-enable-bit: Regulator enable bit offset

Any property defined as part of the core regulator
binding, defined in regulator.txt, can also be used.
+34 −0
Original line number Diff line number Diff line
Motorola CPCAP PMIC voltage regulators
------------------------------------

Requires node properties:
- "compatible" value one of:
    "motorola,cpcap-regulator"
    "motorola,mapphone-cpcap-regulator"

Required regulator properties:
- "regulator-name"
- "regulator-enable-ramp-delay"
- "regulator-min-microvolt"
- "regulator-max-microvolt"

Optional regulator properties:
- "regulator-boot-on"

See Documentation/devicetree/bindings/regulator/regulator.txt
for more details about the regulator properties.

Example:

cpcap_regulator: regulator {
	compatible = "motorola,cpcap-regulator";

	cpcap_regulators: regulators {
		sw5: SW5 {
			regulator-min-microvolt = <5050000>;
			regulator-max-microvolt = <5050000>;
			regulator-enable-ramp-delay = <50000>;
			regulator-boot-on;
		};
	};
};
+1 −1
Original line number Diff line number Diff line
@@ -13,7 +13,7 @@ Optional properties:
- startup-delay-us	: Startup time in microseconds.
- enable-active-high	: Polarity of GPIO is active high (default is low).
- regulator-type	: Specifies what is being regulated, must be either
			  "voltage" or "current", defaults to current.
			  "voltage" or "current", defaults to voltage.

Any property defined as part of the core regulator binding defined in
regulator.txt can also be used.
+56 −0
Original line number Diff line number Diff line
@@ -22,6 +22,7 @@ Regulator nodes are identified by their compatible:
		    "qcom,rpm-pm8841-regulators"
		    "qcom,rpm-pm8916-regulators"
		    "qcom,rpm-pm8941-regulators"
		    "qcom,rpm-pm8994-regulators"
		    "qcom,rpm-pma8084-regulators"

- vdd_s1-supply:
@@ -68,6 +69,56 @@ Regulator nodes are identified by their compatible:
	Definition: reference to regulator supplying the input pin, as
		    described in the data sheet

- vdd_s1-supply:
- vdd_s2-supply:
- vdd_s3-supply:
- vdd_s4-supply:
- vdd_s5-supply:
- vdd_s6-supply:
- vdd_s7-supply:
- vdd_s8-supply:
- vdd_s9-supply:
- vdd_s10-supply:
- vdd_s11-supply:
- vdd_s12-supply:
- vdd_l1-supply:
- vdd_l2_l26_l28-supply:
- vdd_l3_l11-supply:
- vdd_l4_l27_l31-supply:
- vdd_l5_l7-supply:
- vdd_l6_l12_l32-supply:
- vdd_l5_l7-supply:
- vdd_l8_l16_l30-supply:
- vdd_l9_l10_l18_l22-supply:
- vdd_l9_l10_l18_l22-supply:
- vdd_l3_l11-supply:
- vdd_l6_l12_l32-supply:
- vdd_l13_l19_l23_l24-supply:
- vdd_l14_l15-supply:
- vdd_l14_l15-supply:
- vdd_l8_l16_l30-supply:
- vdd_l17_l29-supply:
- vdd_l9_l10_l18_l22-supply:
- vdd_l13_l19_l23_l24-supply:
- vdd_l20_l21-supply:
- vdd_l20_l21-supply:
- vdd_l9_l10_l18_l22-supply:
- vdd_l13_l19_l23_l24-supply:
- vdd_l13_l19_l23_l24-supply:
- vdd_l25-supply:
- vdd_l2_l26_l28-supply:
- vdd_l4_l27_l31-supply:
- vdd_l2_l26_l28-supply:
- vdd_l17_l29-supply:
- vdd_l8_l16_l30-supply:
- vdd_l4_l27_l31-supply:
- vdd_l6_l12_l32-supply:
- vdd_lvs1_2-supply:
	Usage: optional (pm8994 only)
	Value type: <phandle>
	Definition: reference to regulator supplying the input pin, as
		    described in the data sheet

- vdd_s1-supply:
- vdd_s2-supply:
- vdd_s3-supply:
@@ -113,6 +164,11 @@ pm8941:
	l14, l15, l16, l17, l18, l19, l20, l21, l22, l23, l24, lvs1, lvs2,
	lvs3, 5vs1, 5vs2

pm8994:
	s1, s2, s3, s4, s5, s6, s7, s8, s9, s10, s11, s12, l1, l2, l3, l4, l5,
	l6, l7, l8, l9, l10, l11, l12, l13, l14, l15, l16, l17, l18, l19, l20,
	l21, l22, l23, l24, l25, l26, l27, l28, l29, l30, l31, l32, lvs1, lvs2

pma8084:
	s1, s2, s3, s4, s5, s6, s7, s8, s9, s10, s11, s12, l1, l2, l3, l4, l5,
	l6, l7, l8, l9, l10, l11, l12, l13, l14, l15, l16, l17, l18, l19, l20,
+2 −2
Original line number Diff line number Diff line
@@ -180,7 +180,7 @@ static int pm800_get_current_limit(struct regulator_dev *rdev)
	return info->max_ua;
}

static struct regulator_ops pm800_volt_range_ops = {
static const struct regulator_ops pm800_volt_range_ops = {
	.list_voltage		= regulator_list_voltage_linear_range,
	.map_voltage		= regulator_map_voltage_linear_range,
	.set_voltage_sel	= regulator_set_voltage_sel_regmap,
@@ -191,7 +191,7 @@ static struct regulator_ops pm800_volt_range_ops = {
	.get_current_limit	= pm800_get_current_limit,
};

static struct regulator_ops pm800_volt_table_ops = {
static const struct regulator_ops pm800_volt_table_ops = {
	.list_voltage		= regulator_list_voltage_table,
	.map_voltage		= regulator_map_voltage_iterate,
	.set_voltage_sel	= regulator_set_voltage_sel_regmap,
Loading