Commit 44f7a379 authored by Linus Torvalds's avatar Linus Torvalds
Browse files
Pull regulator updates from Mark Brown:
 "This has been a very quiet update for the regulator API, the bulk of
  the diffstat is DT binding conversions and the most promient series in
  the changelog is Johan Hovold cleaning up some leaks of OF nodes. For
  some reason we have had several different people sending improvements
  to better describe the parent supplies for existing regulators, these
  look to be independent efforts.

  The only new hardware support is for some Motorola custom varints of
  cpcap"

* tag 'regulator-v7.1' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator: (35 commits)
  regulator: max77620: drop redundant OF node initialisation
  regulator: bq257xx: Make OTG enable GPIO really optional
  regulator: bq257xx: Remove reference to the parent MFD's dev
  regulator: bd9571mwv: fix OF node reference imbalance
  regulator: act8945a: fix OF node reference imbalance
  regulator: s2dos05: fix OF node reference imbalance
  regulator: mt6357: fix OF node reference imbalance
  regulator: max77650: fix OF node reference imbalance
  regulator: rk808: fix OF node reference imbalance
  regulator: bq257xx: fix OF node reference imbalance
  regulator: dt-bindings: qcom,qca6390-pmu: Document WCN6755 PMU
  regulator: dt-bindings: regulator-max77620: convert to DT schema
  regulator: mt6315: Add regulator supplies
  regulator: dt-bindings: mt6315: Add regulator supplies
  regulator: devres: Use enum regulator_get_type in internal functions
  regulator: dt-bindings: mps,mp8859: convert to DT schema
  regulator: da9121: Allow caching BUCK registers
  regulator: dt-bindings: dlg,da9121: Add dlg,no-gpio-control
  regulator: cros-ec: Add regulator supply
  regulator: dt-bindings: cros-ec: Add regulator supply
  ...
parents 8e258317 606c780b
Loading
Loading
Loading
Loading
+47 −2
Original line number Diff line number Diff line
@@ -27,8 +27,41 @@ properties:
  interrupts:
    maxItems: 1

  vin-supply:
    description: Input supply phandle.
  vin1-supply:
    description:
      Power supply for BUCK1. Required if BUCK1 is defined.

  vin2-supply:
    description:
      Power supply for BUCK2. Required if BUCK2 is defined.

  vin3-supply:
    description:
      Power supply for BUCK3. Required if BUCK3 is defined.

  vin4-supply:
    description:
      Power supply for BUCK4. Required if BUCK4 is defined.

  vin5-supply:
    description:
      Power supply for BUCK5. Required if BUCK5 is defined.

  vin6-supply:
    description:
      Power supply for BUCK6. Required if BUCK6 is defined.

  aldoin-supply:
    description:
      Power supply for ALDO1-4. Required if any are defined.

  dldoin1-supply:
    description:
      Power supply for DLDO1-4. Required if any are defined.

  dldoin2-supply:
    description:
      Power supply for DLDO5-7. Required if any are defined.

  regulators:
    type: object
@@ -58,6 +91,10 @@ examples:
            compatible = "spacemit,p1";
            reg = <0x41>;
            interrupts = <64>;
            vin1-supply = <&reg_vcc_5v>;
            vin5-supply = <&reg_vcc_5v>;
            aldoin-supply = <&reg_vcc_5v>;
            dldoin1-supply = <&buck5>;

            regulators {
                buck1 {
@@ -68,6 +105,14 @@ examples:
                    regulator-always-on;
                };

                buck5: buck5 {
                    regulator-name = "buck5";
                    regulator-min-microvolt = <500000>;
                    regulator-max-microvolt = <3450000>;
                    regulator-ramp-delay = <5000>;
                    regulator-always-on;
                };

                aldo1 {
                    regulator-name = "aldo1";
                    regulator-min-microvolt = <500000>;
+0 −35
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"
    "motorola,xoom-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;
		};
	};
};
+49 −0
Original line number Diff line number Diff line
@@ -81,6 +81,14 @@ properties:
      Specify the polling period, measured in milliseconds, between interrupt status
      update checks. Range 1000-10000 ms.

  dlg,no-gpio-control:
    type: boolean
    description: |
      Available GPIO input pins of the regulator are strapped to fixed levels, therefore
      GPIO configurable input functions, DVC/RELOAD/EN, cannot dynamically update BUCK
      registers. GPIO pins connected as output pins are not required to be strapped to a
      fixed level. Not allowed together with enable-gpios.

  regulators:
    type: object
    additionalProperties: false
@@ -134,6 +142,17 @@ allOf:
          properties:
            buck2: false

  - if:
      required:
        - dlg,no-gpio-control
    then:
      properties:
        regulators:
          patternProperties:
            "^buck([1-2])$":
              properties:
                enable-gpios: false

additionalProperties: false

examples:
@@ -168,6 +187,36 @@ examples:
      };
    };

  - |
    #include <dt-bindings/interrupt-controller/irq.h>
    #include <dt-bindings/regulator/dlg,da9121-regulator.h>
    i2c {
      #address-cells = <1>;
      #size-cells = <0>;
      pmic@68 {
        compatible = "dlg,da9121";
        reg = <0x68>;

        interrupt-parent = <&gpio6>;
        interrupts = <11 IRQ_TYPE_LEVEL_LOW>;

        dlg,irq-polling-delay-passive-ms = <2000>;
        dlg,no-gpio-control;

        regulators {
          DA9121_BUCK: buck1 {
            regulator-name = "BUCK1";
            regulator-min-microvolt = <300000>;
            regulator-max-microvolt = <1900000>;
            regulator-min-microamp = <7000000>;
            regulator-max-microamp = <20000000>;
            regulator-boot-on;
            regulator-initial-mode = <DA9121_BUCK_MODE_AUTO>;
          };
        };
      };
    };

  - |
    #include <dt-bindings/gpio/gpio.h>
    #include <dt-bindings/interrupt-controller/irq.h>
+1 −0
Original line number Diff line number Diff line
@@ -66,6 +66,7 @@ properties:
required:
  - compatible
  - reg
  - vin-supply
  - pg-gpios
  - enable-gpios

+4 −0
Original line number Diff line number Diff line
@@ -24,6 +24,9 @@ properties:
    maxItems: 1
    description: Identifier for the voltage regulator to ChromeOS EC.

  vin-supply:
    description: Input supply phandle

required:
  - compatible
  - reg
@@ -48,6 +51,7 @@ examples:
                regulator-min-microvolt = <1800000>;
                regulator-max-microvolt = <3300000>;
                reg = <0>;
                vin-supply = <&pp4200_s5>;
            };
        };
    };
Loading