xref: /freebsd/sys/contrib/device-tree/Bindings/pinctrl/qcom,sm8550-lpass-lpi-pinctrl.yaml (revision 8d13bc63c0e1d50bc9e47ac1f26329c999bfecf0)
1cb7aa33aSEmmanuel Vadot# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2cb7aa33aSEmmanuel Vadot%YAML 1.2
3cb7aa33aSEmmanuel Vadot---
4cb7aa33aSEmmanuel Vadot$id: http://devicetree.org/schemas/pinctrl/qcom,sm8550-lpass-lpi-pinctrl.yaml#
5cb7aa33aSEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml#
6cb7aa33aSEmmanuel Vadot
7cb7aa33aSEmmanuel Vadottitle: Qualcomm SM8550 SoC LPASS LPI TLMM
8cb7aa33aSEmmanuel Vadot
9cb7aa33aSEmmanuel Vadotmaintainers:
10cb7aa33aSEmmanuel Vadot  - Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
11cb7aa33aSEmmanuel Vadot  - Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
12cb7aa33aSEmmanuel Vadot
13cb7aa33aSEmmanuel Vadotdescription:
14cb7aa33aSEmmanuel Vadot  Top Level Mode Multiplexer pin controller in the Low Power Audio SubSystem
15cb7aa33aSEmmanuel Vadot  (LPASS) Low Power Island (LPI) of Qualcomm SM8550 SoC.
16cb7aa33aSEmmanuel Vadot
17cb7aa33aSEmmanuel Vadotproperties:
18cb7aa33aSEmmanuel Vadot  compatible:
19*8d13bc63SEmmanuel Vadot    oneOf:
20*8d13bc63SEmmanuel Vadot      - const: qcom,sm8550-lpass-lpi-pinctrl
21*8d13bc63SEmmanuel Vadot      - items:
22*8d13bc63SEmmanuel Vadot          - const: qcom,x1e80100-lpass-lpi-pinctrl
23*8d13bc63SEmmanuel Vadot          - const: qcom,sm8550-lpass-lpi-pinctrl
24cb7aa33aSEmmanuel Vadot
25cb7aa33aSEmmanuel Vadot  reg:
26cb7aa33aSEmmanuel Vadot    items:
27cb7aa33aSEmmanuel Vadot      - description: LPASS LPI TLMM Control and Status registers
28fac71e4eSEmmanuel Vadot      - description: LPASS LPI MCC registers
29cb7aa33aSEmmanuel Vadot
30cb7aa33aSEmmanuel Vadot  clocks:
31cb7aa33aSEmmanuel Vadot    items:
32cb7aa33aSEmmanuel Vadot      - description: LPASS Core voting clock
33cb7aa33aSEmmanuel Vadot      - description: LPASS Audio voting clock
34cb7aa33aSEmmanuel Vadot
35cb7aa33aSEmmanuel Vadot  clock-names:
36cb7aa33aSEmmanuel Vadot    items:
37cb7aa33aSEmmanuel Vadot      - const: core
38cb7aa33aSEmmanuel Vadot      - const: audio
39cb7aa33aSEmmanuel Vadot
40cb7aa33aSEmmanuel VadotpatternProperties:
41cb7aa33aSEmmanuel Vadot  "-state$":
42cb7aa33aSEmmanuel Vadot    oneOf:
43cb7aa33aSEmmanuel Vadot      - $ref: "#/$defs/qcom-sm8550-lpass-state"
44cb7aa33aSEmmanuel Vadot      - patternProperties:
45cb7aa33aSEmmanuel Vadot          "-pins$":
46cb7aa33aSEmmanuel Vadot            $ref: "#/$defs/qcom-sm8550-lpass-state"
47cb7aa33aSEmmanuel Vadot        additionalProperties: false
48cb7aa33aSEmmanuel Vadot
49cb7aa33aSEmmanuel Vadot$defs:
50cb7aa33aSEmmanuel Vadot  qcom-sm8550-lpass-state:
51cb7aa33aSEmmanuel Vadot    type: object
52cb7aa33aSEmmanuel Vadot    description:
53cb7aa33aSEmmanuel Vadot      Pinctrl node's client devices use subnodes for desired pin configuration.
54cb7aa33aSEmmanuel Vadot      Client device subnodes use below standard properties.
55*8d13bc63SEmmanuel Vadot    $ref: qcom,lpass-lpi-common.yaml#/$defs/qcom-tlmm-state
56*8d13bc63SEmmanuel Vadot    unevaluatedProperties: false
57cb7aa33aSEmmanuel Vadot
58cb7aa33aSEmmanuel Vadot    properties:
59cb7aa33aSEmmanuel Vadot      pins:
60cb7aa33aSEmmanuel Vadot        description:
61cb7aa33aSEmmanuel Vadot          List of gpio pins affected by the properties specified in this
62cb7aa33aSEmmanuel Vadot          subnode.
63cb7aa33aSEmmanuel Vadot        items:
64cb7aa33aSEmmanuel Vadot          pattern: "^gpio([0-9]|1[0-9]|2[0-2])$"
65cb7aa33aSEmmanuel Vadot
66cb7aa33aSEmmanuel Vadot      function:
67cb7aa33aSEmmanuel Vadot        enum: [ dmic1_clk, dmic1_data, dmic2_clk, dmic2_data, dmic3_clk,
68cb7aa33aSEmmanuel Vadot                dmic3_data, dmic4_clk, dmic4_data, ext_mclk1_a, ext_mclk1_b,
69cb7aa33aSEmmanuel Vadot                ext_mclk1_c, ext_mclk1_d, ext_mclk1_e, gpio, i2s0_clk,
70cb7aa33aSEmmanuel Vadot                i2s0_data, i2s0_ws, i2s1_clk, i2s1_data, i2s1_ws, i2s2_clk,
71cb7aa33aSEmmanuel Vadot                i2s2_data, i2s2_ws, i2s3_clk, i2s3_data, i2s3_ws, i2s4_clk,
72cb7aa33aSEmmanuel Vadot                i2s4_data, i2s4_ws, slimbus_clk, slimbus_data, swr_rx_clk,
73cb7aa33aSEmmanuel Vadot                swr_rx_data, swr_tx_clk, swr_tx_data, wsa_swr_clk,
74cb7aa33aSEmmanuel Vadot                wsa_swr_data, wsa2_swr_clk, wsa2_swr_data ]
75cb7aa33aSEmmanuel Vadot        description:
76cb7aa33aSEmmanuel Vadot          Specify the alternative function to be configured for the specified
77cb7aa33aSEmmanuel Vadot          pins.
78cb7aa33aSEmmanuel Vadot
79cb7aa33aSEmmanuel VadotallOf:
80*8d13bc63SEmmanuel Vadot  - $ref: qcom,lpass-lpi-common.yaml#
81cb7aa33aSEmmanuel Vadot
82cb7aa33aSEmmanuel Vadotrequired:
83cb7aa33aSEmmanuel Vadot  - compatible
84cb7aa33aSEmmanuel Vadot  - reg
85cb7aa33aSEmmanuel Vadot  - clocks
86cb7aa33aSEmmanuel Vadot  - clock-names
87cb7aa33aSEmmanuel Vadot
88*8d13bc63SEmmanuel VadotunevaluatedProperties: false
89cb7aa33aSEmmanuel Vadot
90cb7aa33aSEmmanuel Vadotexamples:
91cb7aa33aSEmmanuel Vadot  - |
92cb7aa33aSEmmanuel Vadot    #include <dt-bindings/sound/qcom,q6dsp-lpass-ports.h>
93cb7aa33aSEmmanuel Vadot
94cb7aa33aSEmmanuel Vadot    lpass_tlmm: pinctrl@6e80000 {
95cb7aa33aSEmmanuel Vadot        compatible = "qcom,sm8550-lpass-lpi-pinctrl";
96cb7aa33aSEmmanuel Vadot        reg = <0x06e80000 0x20000>,
97cb7aa33aSEmmanuel Vadot              <0x0725a000 0x10000>;
98cb7aa33aSEmmanuel Vadot
99cb7aa33aSEmmanuel Vadot        clocks = <&q6prmcc LPASS_HW_MACRO_VOTE LPASS_CLK_ATTRIBUTE_COUPLE_NO>,
100cb7aa33aSEmmanuel Vadot                 <&q6prmcc LPASS_HW_DCODEC_VOTE LPASS_CLK_ATTRIBUTE_COUPLE_NO>;
101cb7aa33aSEmmanuel Vadot        clock-names = "core", "audio";
102cb7aa33aSEmmanuel Vadot
103cb7aa33aSEmmanuel Vadot        gpio-controller;
104cb7aa33aSEmmanuel Vadot        #gpio-cells = <2>;
105cb7aa33aSEmmanuel Vadot        gpio-ranges = <&lpass_tlmm 0 0 23>;
106cb7aa33aSEmmanuel Vadot
107cb7aa33aSEmmanuel Vadot        tx-swr-sleep-clk-state {
108cb7aa33aSEmmanuel Vadot            pins = "gpio0";
109cb7aa33aSEmmanuel Vadot            function = "swr_tx_clk";
110cb7aa33aSEmmanuel Vadot            drive-strength = <2>;
111cb7aa33aSEmmanuel Vadot            bias-pull-down;
112cb7aa33aSEmmanuel Vadot        };
113cb7aa33aSEmmanuel Vadot    };
114