xref: /linux/Documentation/devicetree/bindings/pinctrl/qcom,sc8280xp-lpass-lpi-pinctrl.yaml (revision b47a6c8b771c62140b619a288acdd5ee46e29272)
1958bb025SSrinivas Kandagatla# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2958bb025SSrinivas Kandagatla%YAML 1.2
3958bb025SSrinivas Kandagatla---
4958bb025SSrinivas Kandagatla$id: http://devicetree.org/schemas/pinctrl/qcom,sc8280xp-lpass-lpi-pinctrl.yaml#
5958bb025SSrinivas Kandagatla$schema: http://devicetree.org/meta-schemas/core.yaml#
6958bb025SSrinivas Kandagatla
7958bb025SSrinivas Kandagatlatitle: Qualcomm Technologies, Inc. Low Power Audio SubSystem (LPASS)
8958bb025SSrinivas Kandagatla  Low Power Island (LPI) TLMM block
9958bb025SSrinivas Kandagatla
10958bb025SSrinivas Kandagatlamaintainers:
11958bb025SSrinivas Kandagatla  - Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
12958bb025SSrinivas Kandagatla
13958bb025SSrinivas Kandagatladescription: |
14958bb025SSrinivas Kandagatla  This binding describes the Top Level Mode Multiplexer block found in the
15958bb025SSrinivas Kandagatla  LPASS LPI IP on most Qualcomm SoCs
16958bb025SSrinivas Kandagatla
17958bb025SSrinivas Kandagatlaproperties:
18958bb025SSrinivas Kandagatla  compatible:
19958bb025SSrinivas Kandagatla    const: qcom,sc8280xp-lpass-lpi-pinctrl
20958bb025SSrinivas Kandagatla
21958bb025SSrinivas Kandagatla  reg:
22958bb025SSrinivas Kandagatla    items:
23958bb025SSrinivas Kandagatla      - description: LPASS LPI TLMM Control and Status registers
24958bb025SSrinivas Kandagatla      - description: LPASS LPI pins SLEW registers
25958bb025SSrinivas Kandagatla
26958bb025SSrinivas Kandagatla  clocks:
27958bb025SSrinivas Kandagatla    items:
28958bb025SSrinivas Kandagatla      - description: LPASS Core voting clock
29958bb025SSrinivas Kandagatla      - description: LPASS Audio voting clock
30958bb025SSrinivas Kandagatla
31958bb025SSrinivas Kandagatla  clock-names:
32958bb025SSrinivas Kandagatla    items:
33958bb025SSrinivas Kandagatla      - const: core
34958bb025SSrinivas Kandagatla      - const: audio
35958bb025SSrinivas Kandagatla
36958bb025SSrinivas Kandagatla  gpio-controller: true
37958bb025SSrinivas Kandagatla
38958bb025SSrinivas Kandagatla  '#gpio-cells':
39958bb025SSrinivas Kandagatla    description: Specifying the pin number and flags, as defined in
40958bb025SSrinivas Kandagatla      include/dt-bindings/gpio/gpio.h
41958bb025SSrinivas Kandagatla    const: 2
42958bb025SSrinivas Kandagatla
43958bb025SSrinivas Kandagatla  gpio-ranges:
44958bb025SSrinivas Kandagatla    maxItems: 1
45958bb025SSrinivas Kandagatla
46958bb025SSrinivas KandagatlapatternProperties:
47*b47a6c8bSKrzysztof Kozlowski  "-state$":
48*b47a6c8bSKrzysztof Kozlowski    oneOf:
49*b47a6c8bSKrzysztof Kozlowski      - $ref: "#/$defs/qcom-sc8280xp-lpass-state"
50*b47a6c8bSKrzysztof Kozlowski      - patternProperties:
51*b47a6c8bSKrzysztof Kozlowski          "-pins$":
52*b47a6c8bSKrzysztof Kozlowski            $ref: "#/$defs/qcom-sc8280xp-lpass-state"
53*b47a6c8bSKrzysztof Kozlowski        additionalProperties: false
54*b47a6c8bSKrzysztof Kozlowski
55*b47a6c8bSKrzysztof Kozlowski$defs:
56*b47a6c8bSKrzysztof Kozlowski  qcom-sc8280xp-lpass-state:
57958bb025SSrinivas Kandagatla    type: object
58958bb025SSrinivas Kandagatla    description:
59958bb025SSrinivas Kandagatla      Pinctrl node's client devices use subnodes for desired pin configuration.
60958bb025SSrinivas Kandagatla      Client device subnodes use below standard properties.
61958bb025SSrinivas Kandagatla    $ref: /schemas/pinctrl/pincfg-node.yaml
62958bb025SSrinivas Kandagatla
63958bb025SSrinivas Kandagatla    properties:
64958bb025SSrinivas Kandagatla      pins:
65958bb025SSrinivas Kandagatla        description:
66958bb025SSrinivas Kandagatla          List of gpio pins affected by the properties specified in this
67958bb025SSrinivas Kandagatla          subnode.
68958bb025SSrinivas Kandagatla        items:
69793b96bfSKrzysztof Kozlowski          pattern: "^gpio([0-1]|1[0-8])$"
70958bb025SSrinivas Kandagatla
71958bb025SSrinivas Kandagatla      function:
72958bb025SSrinivas Kandagatla        enum: [ swr_tx_clk, swr_tx_data, swr_rx_clk, swr_rx_data,
73958bb025SSrinivas Kandagatla                dmic1_clk, dmic1_data, dmic2_clk, dmic2_data, dmic4_clk,
74958bb025SSrinivas Kandagatla                dmic4_data, i2s2_clk, i2s2_ws, dmic3_clk, dmic3_data,
75958bb025SSrinivas Kandagatla                qua_mi2s_sclk, qua_mi2s_ws, qua_mi2s_data, i2s1_clk, i2s1_ws,
76958bb025SSrinivas Kandagatla                i2s1_data, wsa_swr_clk, wsa_swr_data, wsa2_swr_clk,
77958bb025SSrinivas Kandagatla                wsa2_swr_data, i2s2_data, i2s3_clk, i2s3_ws, i2s3_data,
78958bb025SSrinivas Kandagatla                ext_mclk1_c, ext_mclk1_b, ext_mclk1_a ]
79958bb025SSrinivas Kandagatla        description:
80958bb025SSrinivas Kandagatla          Specify the alternative function to be configured for the specified
81958bb025SSrinivas Kandagatla          pins.
82958bb025SSrinivas Kandagatla
83958bb025SSrinivas Kandagatla      drive-strength:
84958bb025SSrinivas Kandagatla        enum: [2, 4, 6, 8, 10, 12, 14, 16]
85958bb025SSrinivas Kandagatla        default: 2
86958bb025SSrinivas Kandagatla        description:
87958bb025SSrinivas Kandagatla          Selects the drive strength for the specified pins, in mA.
88958bb025SSrinivas Kandagatla
89958bb025SSrinivas Kandagatla      slew-rate:
90958bb025SSrinivas Kandagatla        enum: [0, 1, 2, 3]
91958bb025SSrinivas Kandagatla        default: 0
92958bb025SSrinivas Kandagatla        description: |
93958bb025SSrinivas Kandagatla          0: No adjustments
94958bb025SSrinivas Kandagatla          1: Higher Slew rate (faster edges)
95958bb025SSrinivas Kandagatla          2: Lower Slew rate (slower edges)
96958bb025SSrinivas Kandagatla          3: Reserved (No adjustments)
97958bb025SSrinivas Kandagatla
98958bb025SSrinivas Kandagatla      bias-pull-down: true
99958bb025SSrinivas Kandagatla
100958bb025SSrinivas Kandagatla      bias-pull-up: true
101958bb025SSrinivas Kandagatla
102958bb025SSrinivas Kandagatla      bias-disable: true
103958bb025SSrinivas Kandagatla
104958bb025SSrinivas Kandagatla      output-high: true
105958bb025SSrinivas Kandagatla
106958bb025SSrinivas Kandagatla      output-low: true
107958bb025SSrinivas Kandagatla
108958bb025SSrinivas Kandagatla    required:
109958bb025SSrinivas Kandagatla      - pins
110958bb025SSrinivas Kandagatla      - function
111958bb025SSrinivas Kandagatla
112958bb025SSrinivas Kandagatla    additionalProperties: false
113958bb025SSrinivas Kandagatla
114958bb025SSrinivas KandagatlaallOf:
115958bb025SSrinivas Kandagatla  - $ref: pinctrl.yaml#
116958bb025SSrinivas Kandagatla
117958bb025SSrinivas Kandagatlarequired:
118958bb025SSrinivas Kandagatla  - compatible
119958bb025SSrinivas Kandagatla  - reg
120958bb025SSrinivas Kandagatla  - clocks
121958bb025SSrinivas Kandagatla  - clock-names
122958bb025SSrinivas Kandagatla  - gpio-controller
123958bb025SSrinivas Kandagatla  - '#gpio-cells'
124958bb025SSrinivas Kandagatla  - gpio-ranges
125958bb025SSrinivas Kandagatla
126958bb025SSrinivas KandagatlaadditionalProperties: false
127958bb025SSrinivas Kandagatla
128958bb025SSrinivas Kandagatlaexamples:
129958bb025SSrinivas Kandagatla  - |
130958bb025SSrinivas Kandagatla    #include <dt-bindings/sound/qcom,q6afe.h>
131958bb025SSrinivas Kandagatla    pinctrl@33c0000 {
132958bb025SSrinivas Kandagatla        compatible = "qcom,sc8280xp-lpass-lpi-pinctrl";
133958bb025SSrinivas Kandagatla        reg = <0x33c0000 0x20000>,
134958bb025SSrinivas Kandagatla              <0x3550000 0x10000>;
135958bb025SSrinivas Kandagatla        clocks = <&q6afecc LPASS_HW_MACRO_VOTE LPASS_CLK_ATTRIBUTE_COUPLE_NO>,
136958bb025SSrinivas Kandagatla                 <&q6afecc LPASS_HW_DCODEC_VOTE LPASS_CLK_ATTRIBUTE_COUPLE_NO>;
137958bb025SSrinivas Kandagatla        clock-names = "core", "audio";
138958bb025SSrinivas Kandagatla        gpio-controller;
139958bb025SSrinivas Kandagatla        #gpio-cells = <2>;
140958bb025SSrinivas Kandagatla        gpio-ranges = <&lpi_tlmm 0 0 18>;
141*b47a6c8bSKrzysztof Kozlowski
142*b47a6c8bSKrzysztof Kozlowski        dmic01-state {
143*b47a6c8bSKrzysztof Kozlowski            dmic01-clk-pins {
144*b47a6c8bSKrzysztof Kozlowski                pins = "gpio16";
145*b47a6c8bSKrzysztof Kozlowski                function = "dmic1_clk";
146*b47a6c8bSKrzysztof Kozlowski            };
147*b47a6c8bSKrzysztof Kozlowski
148*b47a6c8bSKrzysztof Kozlowski            dmic01-clk-sleep-pins {
149*b47a6c8bSKrzysztof Kozlowski                pins = "gpio16";
150*b47a6c8bSKrzysztof Kozlowski                function = "dmic1_clk";
151*b47a6c8bSKrzysztof Kozlowski            };
152*b47a6c8bSKrzysztof Kozlowski        };
153*b47a6c8bSKrzysztof Kozlowski
154*b47a6c8bSKrzysztof Kozlowski        tx-swr-data-sleep-state {
155*b47a6c8bSKrzysztof Kozlowski            pins = "gpio0", "gpio1";
156*b47a6c8bSKrzysztof Kozlowski            function = "swr_tx_data";
157*b47a6c8bSKrzysztof Kozlowski        };
158958bb025SSrinivas Kandagatla    };
159