xref: /linux/Documentation/devicetree/bindings/arm/tegra/nvidia,tegra186-pmc.yaml (revision 79790b6818e96c58fe2bffee1b418c16e64e7b80)
15cda3b25SThierry Reding# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
25cda3b25SThierry Reding%YAML 1.2
35cda3b25SThierry Reding---
45cda3b25SThierry Reding$id: http://devicetree.org/schemas/arm/tegra/nvidia,tegra186-pmc.yaml#
55cda3b25SThierry Reding$schema: http://devicetree.org/meta-schemas/core.yaml#
65cda3b25SThierry Reding
75cda3b25SThierry Redingtitle: NVIDIA Tegra Power Management Controller (PMC)
85cda3b25SThierry Reding
95cda3b25SThierry Redingmaintainers:
105cda3b25SThierry Reding  - Thierry Reding <thierry.reding@gmail.com>
115cda3b25SThierry Reding  - Jon Hunter <jonathanh@nvidia.com>
125cda3b25SThierry Reding
135cda3b25SThierry Redingproperties:
145cda3b25SThierry Reding  compatible:
155cda3b25SThierry Reding    enum:
165cda3b25SThierry Reding      - nvidia,tegra186-pmc
175cda3b25SThierry Reding      - nvidia,tegra194-pmc
185cda3b25SThierry Reding      - nvidia,tegra234-pmc
195cda3b25SThierry Reding
205cda3b25SThierry Reding  reg:
215cda3b25SThierry Reding    minItems: 4
225cda3b25SThierry Reding    maxItems: 5
235cda3b25SThierry Reding
245cda3b25SThierry Reding  reg-names:
255cda3b25SThierry Reding    minItems: 4
265cda3b25SThierry Reding    items:
275cda3b25SThierry Reding      - const: pmc
285cda3b25SThierry Reding      - const: wake
295cda3b25SThierry Reding      - const: aotag
30*4e00c62bSPetlozu Pravareshwar      - enum: [ scratch, misc ]
315cda3b25SThierry Reding      - const: misc
325cda3b25SThierry Reding
335cda3b25SThierry Reding  interrupt-controller: true
345cda3b25SThierry Reding
355cda3b25SThierry Reding  "#interrupt-cells":
365cda3b25SThierry Reding    description: Specifies the number of cells needed to encode an
375cda3b25SThierry Reding      interrupt source. The value must be 2.
385cda3b25SThierry Reding    const: 2
395cda3b25SThierry Reding
405cda3b25SThierry Reding  nvidia,invert-interrupt:
415cda3b25SThierry Reding    description: If present, inverts the PMU interrupt signal.
425cda3b25SThierry Reding    $ref: /schemas/types.yaml#/definitions/flag
435cda3b25SThierry Reding
44*4e00c62bSPetlozu PravareshwarallOf:
45*4e00c62bSPetlozu Pravareshwar  - if:
465cda3b25SThierry Reding      properties:
475cda3b25SThierry Reding        compatible:
485cda3b25SThierry Reding          contains:
495cda3b25SThierry Reding            const: nvidia,tegra186-pmc
505cda3b25SThierry Reding    then:
515cda3b25SThierry Reding      properties:
525cda3b25SThierry Reding        reg:
535cda3b25SThierry Reding          maxItems: 4
545cda3b25SThierry Reding        reg-names:
555cda3b25SThierry Reding          maxItems: 4
56*4e00c62bSPetlozu Pravareshwar          contains:
57*4e00c62bSPetlozu Pravareshwar            const: scratch
58*4e00c62bSPetlozu Pravareshwar
59*4e00c62bSPetlozu Pravareshwar  - if:
60*4e00c62bSPetlozu Pravareshwar      properties:
61*4e00c62bSPetlozu Pravareshwar        compatible:
62*4e00c62bSPetlozu Pravareshwar          contains:
63*4e00c62bSPetlozu Pravareshwar            const: nvidia,tegra194-pmc
64*4e00c62bSPetlozu Pravareshwar    then:
655cda3b25SThierry Reding      properties:
665cda3b25SThierry Reding        reg:
675cda3b25SThierry Reding          minItems: 5
685cda3b25SThierry Reding        reg-names:
695cda3b25SThierry Reding          minItems: 5
705cda3b25SThierry Reding
71*4e00c62bSPetlozu Pravareshwar  - if:
72*4e00c62bSPetlozu Pravareshwar      properties:
73*4e00c62bSPetlozu Pravareshwar        compatible:
74*4e00c62bSPetlozu Pravareshwar          contains:
75*4e00c62bSPetlozu Pravareshwar            const: nvidia,tegra234-pmc
76*4e00c62bSPetlozu Pravareshwar    then:
77*4e00c62bSPetlozu Pravareshwar      properties:
78*4e00c62bSPetlozu Pravareshwar        reg-names:
79*4e00c62bSPetlozu Pravareshwar          contains:
80*4e00c62bSPetlozu Pravareshwar            const: misc
81*4e00c62bSPetlozu Pravareshwar
825cda3b25SThierry RedingpatternProperties:
835cda3b25SThierry Reding  "^[a-z0-9]+-[a-z0-9]+$":
845cda3b25SThierry Reding    if:
855cda3b25SThierry Reding      type: object
865cda3b25SThierry Reding    then:
875cda3b25SThierry Reding      description: |
885cda3b25SThierry Reding        These are pad configuration nodes. On Tegra SoCs a pad is a set of
895cda3b25SThierry Reding        pins which are configured as a group. The pin grouping is a fixed
905cda3b25SThierry Reding        attribute of the hardware. The PMC can be used to set pad power
915cda3b25SThierry Reding        state and signaling voltage. A pad can be either in active or
925cda3b25SThierry Reding        power down mode. The support for power state and signaling voltage
935cda3b25SThierry Reding        configuration varies depending on the pad in question. 3.3 V and
945cda3b25SThierry Reding        1.8 V signaling voltages are supported on pins where software
955cda3b25SThierry Reding        controllable signaling voltage switching is available.
965cda3b25SThierry Reding
975cda3b25SThierry Reding        Pad configurations are described with pin configuration nodes
985cda3b25SThierry Reding        which are placed under the pmc node and they are referred to by
995cda3b25SThierry Reding        the pinctrl client properties. For more information see
1005cda3b25SThierry Reding
1015cda3b25SThierry Reding          Documentation/devicetree/bindings/pinctrl/pinctrl-bindings.txt
1025cda3b25SThierry Reding
1035cda3b25SThierry Reding        The following pads are present on Tegra186:
1045cda3b25SThierry Reding
1055cda3b25SThierry Reding          csia, csib, dsi, mipi-bias, pex-clk-bias, pex-clk3, pex-clk2,
1065cda3b25SThierry Reding          pex-clk1, usb0, usb1, usb2, usb-bias, uart, audio, hsic, dbg,
1075cda3b25SThierry Reding          hdmi-dp0, hdmi-dp1, pex-cntrl, sdmmc2-hv, sdmmc4, cam, dsib,
1085cda3b25SThierry Reding          dsic, dsid, csic, csid, csie, dsif, spi, ufs, dmic-hv, edp,
1095cda3b25SThierry Reding          sdmmc1-hv, sdmmc3-hv, conn, audio-hv, ao-hv
1105cda3b25SThierry Reding
1115cda3b25SThierry Reding        The following pads are present on Tegra194:
1125cda3b25SThierry Reding
1135cda3b25SThierry Reding          csia, csib, mipi-bias, pex-clk-bias, pex-clk3, pex-clk2,
1145cda3b25SThierry Reding          pex-clk1, eqos, pex-clk-2-bias, pex-clk-2, dap3, dap5, uart,
1155cda3b25SThierry Reding          pwr-ctl, soc-gpio53, audio, gp-pwm2, gp-pwm3, soc-gpio12,
1165cda3b25SThierry Reding          soc-gpio13, soc-gpio10, uart4, uart5, dbg, hdmi-dp3, hdmi-dp2,
1175cda3b25SThierry Reding          hdmi-dp0, hdmi-dp1, pex-cntrl, pex-ctl2, pex-l0-rst,
1185cda3b25SThierry Reding          pex-l1-rst, sdmmc4, pex-l5-rst, cam, csic, csid, csie, csif,
1195cda3b25SThierry Reding          spi, ufs, csig, csih, edp, sdmmc1-hv, sdmmc3-hv, conn,
1205cda3b25SThierry Reding          audio-hv, ao-hv
1215cda3b25SThierry Reding
1225cda3b25SThierry Reding      properties:
1235cda3b25SThierry Reding        pins:
1245cda3b25SThierry Reding          $ref: /schemas/types.yaml#/definitions/string
1255cda3b25SThierry Reding          description: Must contain the name of the pad(s) to be
1265cda3b25SThierry Reding            configured.
1275cda3b25SThierry Reding
1285cda3b25SThierry Reding        low-power-enable:
1295cda3b25SThierry Reding          description: Configure the pad into power down mode.
1305cda3b25SThierry Reding          $ref: /schemas/types.yaml#/definitions/flag
1315cda3b25SThierry Reding
1325cda3b25SThierry Reding        low-power-disable:
1335cda3b25SThierry Reding          description: Configure the pad into active mode.
1345cda3b25SThierry Reding          $ref: /schemas/types.yaml#/definitions/flag
1355cda3b25SThierry Reding
1365cda3b25SThierry Reding        power-source:
1375cda3b25SThierry Reding          $ref: /schemas/types.yaml#/definitions/uint32
1385cda3b25SThierry Reding          description: |
1395cda3b25SThierry Reding            Must contain either TEGRA_IO_PAD_VOLTAGE_1V8 or
1405cda3b25SThierry Reding            TEGRA_IO_PAD_VOLTAGE_3V3 to select between signalling
1415cda3b25SThierry Reding            voltages.
1425cda3b25SThierry Reding
1435cda3b25SThierry Reding            The values are defined in
1445cda3b25SThierry Reding
1455cda3b25SThierry Reding              include/dt-bindings/pinctrl/pinctrl-tegra-io-pad.h
1465cda3b25SThierry Reding
1475cda3b25SThierry Reding            The power state can be configured on all of the above pads
1485cda3b25SThierry Reding            except for ao-hv. Following pads have software configurable
1495cda3b25SThierry Reding            signaling voltages: sdmmc2-hv, dmic-hv, sdmmc1-hv, sdmmc3-hv,
1505cda3b25SThierry Reding            audio-hv, ao-hv.
1515cda3b25SThierry Reding
1525cda3b25SThierry Reding        phandle: true
1535cda3b25SThierry Reding
1545cda3b25SThierry Reding      required:
1555cda3b25SThierry Reding        - pins
1565cda3b25SThierry Reding
1575cda3b25SThierry Reding      additionalProperties: false
1585cda3b25SThierry Reding
1595cda3b25SThierry Redingrequired:
1605cda3b25SThierry Reding  - compatible
1615cda3b25SThierry Reding  - reg
1625cda3b25SThierry Reding  - reg-names
1635cda3b25SThierry Reding
1645cda3b25SThierry RedingadditionalProperties: false
1655cda3b25SThierry Reding
1665cda3b25SThierry Redingdependencies:
1675cda3b25SThierry Reding  interrupt-controller: ['#interrupt-cells']
1685cda3b25SThierry Reding  "#interrupt-cells":
1695cda3b25SThierry Reding    required:
1705cda3b25SThierry Reding      - interrupt-controller
1715cda3b25SThierry Reding
1725cda3b25SThierry Redingexamples:
1735cda3b25SThierry Reding  - |
1745cda3b25SThierry Reding    #include <dt-bindings/clock/tegra186-clock.h>
1755cda3b25SThierry Reding    #include <dt-bindings/interrupt-controller/arm-gic.h>
1765cda3b25SThierry Reding    #include <dt-bindings/pinctrl/pinctrl-tegra-io-pad.h>
1775cda3b25SThierry Reding    #include <dt-bindings/memory/tegra186-mc.h>
1785cda3b25SThierry Reding    #include <dt-bindings/reset/tegra186-reset.h>
1795cda3b25SThierry Reding
1805cda3b25SThierry Reding    pmc@c3600000 {
1815cda3b25SThierry Reding        compatible = "nvidia,tegra186-pmc";
1825cda3b25SThierry Reding        reg = <0x0c360000 0x10000>,
1835cda3b25SThierry Reding              <0x0c370000 0x10000>,
1845cda3b25SThierry Reding              <0x0c380000 0x10000>,
1855cda3b25SThierry Reding              <0x0c390000 0x10000>;
1865cda3b25SThierry Reding        reg-names = "pmc", "wake", "aotag", "scratch";
1875cda3b25SThierry Reding        nvidia,invert-interrupt;
1885cda3b25SThierry Reding
1895cda3b25SThierry Reding        sdmmc1_3v3: sdmmc1-3v3 {
1905cda3b25SThierry Reding            pins = "sdmmc1-hv";
1915cda3b25SThierry Reding            power-source = <TEGRA_IO_PAD_VOLTAGE_3V3>;
1925cda3b25SThierry Reding        };
1935cda3b25SThierry Reding
1945cda3b25SThierry Reding        sdmmc1_1v8: sdmmc1-1v8 {
1955cda3b25SThierry Reding            pins = "sdmmc1-hv";
1965cda3b25SThierry Reding            power-source = <TEGRA_IO_PAD_VOLTAGE_1V8>;
1975cda3b25SThierry Reding        };
1985cda3b25SThierry Reding    };
1995cda3b25SThierry Reding
2005cda3b25SThierry Reding    sdmmc1: mmc@3400000 {
2015cda3b25SThierry Reding        compatible = "nvidia,tegra186-sdhci";
2025cda3b25SThierry Reding        reg = <0x03400000 0x10000>;
2035cda3b25SThierry Reding        interrupts = <GIC_SPI 62 IRQ_TYPE_LEVEL_HIGH>;
2045cda3b25SThierry Reding        clocks = <&bpmp TEGRA186_CLK_SDMMC1>,
2055cda3b25SThierry Reding                 <&bpmp TEGRA186_CLK_SDMMC_LEGACY_TM>;
2065cda3b25SThierry Reding        clock-names = "sdhci", "tmclk";
2075cda3b25SThierry Reding        resets = <&bpmp TEGRA186_RESET_SDMMC1>;
2085cda3b25SThierry Reding        reset-names = "sdhci";
2095cda3b25SThierry Reding        interconnects = <&mc TEGRA186_MEMORY_CLIENT_SDMMCRA &emc>,
2105cda3b25SThierry Reding                        <&mc TEGRA186_MEMORY_CLIENT_SDMMCWA &emc>;
2115cda3b25SThierry Reding        interconnect-names = "dma-mem", "write";
2125cda3b25SThierry Reding        iommus = <&smmu TEGRA186_SID_SDMMC1>;
2135cda3b25SThierry Reding        pinctrl-names = "sdmmc-3v3", "sdmmc-1v8";
2145cda3b25SThierry Reding        pinctrl-0 = <&sdmmc1_3v3>;
2155cda3b25SThierry Reding        pinctrl-1 = <&sdmmc1_1v8>;
2165cda3b25SThierry Reding    };
217