xref: /freebsd/sys/contrib/device-tree/Bindings/pinctrl/qcom,sm8650-tlmm.yaml (revision 8d13bc63c0e1d50bc9e47ac1f26329c999bfecf0)
1*8d13bc63SEmmanuel Vadot# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2*8d13bc63SEmmanuel Vadot%YAML 1.2
3*8d13bc63SEmmanuel Vadot---
4*8d13bc63SEmmanuel Vadot$id: http://devicetree.org/schemas/pinctrl/qcom,sm8650-tlmm.yaml#
5*8d13bc63SEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml#
6*8d13bc63SEmmanuel Vadot
7*8d13bc63SEmmanuel Vadottitle: Qualcomm Technologies, Inc. SM8650 TLMM block
8*8d13bc63SEmmanuel Vadot
9*8d13bc63SEmmanuel Vadotmaintainers:
10*8d13bc63SEmmanuel Vadot  - Bjorn Andersson <andersson@kernel.org>
11*8d13bc63SEmmanuel Vadot
12*8d13bc63SEmmanuel Vadotdescription:
13*8d13bc63SEmmanuel Vadot  Top Level Mode Multiplexer pin controller in Qualcomm SM8650 SoC.
14*8d13bc63SEmmanuel Vadot
15*8d13bc63SEmmanuel VadotallOf:
16*8d13bc63SEmmanuel Vadot  - $ref: /schemas/pinctrl/qcom,tlmm-common.yaml#
17*8d13bc63SEmmanuel Vadot
18*8d13bc63SEmmanuel Vadotproperties:
19*8d13bc63SEmmanuel Vadot  compatible:
20*8d13bc63SEmmanuel Vadot    const: qcom,sm8650-tlmm
21*8d13bc63SEmmanuel Vadot
22*8d13bc63SEmmanuel Vadot  reg:
23*8d13bc63SEmmanuel Vadot    maxItems: 1
24*8d13bc63SEmmanuel Vadot
25*8d13bc63SEmmanuel Vadot  interrupts:
26*8d13bc63SEmmanuel Vadot    maxItems: 1
27*8d13bc63SEmmanuel Vadot
28*8d13bc63SEmmanuel Vadot  gpio-reserved-ranges:
29*8d13bc63SEmmanuel Vadot    minItems: 1
30*8d13bc63SEmmanuel Vadot    maxItems: 105
31*8d13bc63SEmmanuel Vadot
32*8d13bc63SEmmanuel Vadot  gpio-line-names:
33*8d13bc63SEmmanuel Vadot    maxItems: 210
34*8d13bc63SEmmanuel Vadot
35*8d13bc63SEmmanuel VadotpatternProperties:
36*8d13bc63SEmmanuel Vadot  "-state$":
37*8d13bc63SEmmanuel Vadot    oneOf:
38*8d13bc63SEmmanuel Vadot      - $ref: "#/$defs/qcom-sm8650-tlmm-state"
39*8d13bc63SEmmanuel Vadot      - patternProperties:
40*8d13bc63SEmmanuel Vadot          "-pins$":
41*8d13bc63SEmmanuel Vadot            $ref: "#/$defs/qcom-sm8650-tlmm-state"
42*8d13bc63SEmmanuel Vadot        additionalProperties: false
43*8d13bc63SEmmanuel Vadot
44*8d13bc63SEmmanuel Vadot$defs:
45*8d13bc63SEmmanuel Vadot  qcom-sm8650-tlmm-state:
46*8d13bc63SEmmanuel Vadot    type: object
47*8d13bc63SEmmanuel Vadot    description:
48*8d13bc63SEmmanuel Vadot      Pinctrl node's client devices use subnodes for desired pin configuration.
49*8d13bc63SEmmanuel Vadot      Client device subnodes use below standard properties.
50*8d13bc63SEmmanuel Vadot    $ref: qcom,tlmm-common.yaml#/$defs/qcom-tlmm-state
51*8d13bc63SEmmanuel Vadot    unevaluatedProperties: false
52*8d13bc63SEmmanuel Vadot
53*8d13bc63SEmmanuel Vadot    properties:
54*8d13bc63SEmmanuel Vadot      pins:
55*8d13bc63SEmmanuel Vadot        description:
56*8d13bc63SEmmanuel Vadot          List of gpio pins affected by the properties specified in this
57*8d13bc63SEmmanuel Vadot          subnode.
58*8d13bc63SEmmanuel Vadot        items:
59*8d13bc63SEmmanuel Vadot          oneOf:
60*8d13bc63SEmmanuel Vadot            - pattern: "^gpio([0-9]|[1-9][0-9]|1[0-9][0-9]|20[0-9])$"
61*8d13bc63SEmmanuel Vadot            - enum: [ ufs_reset, sdc2_clk, sdc2_cmd, sdc2_data ]
62*8d13bc63SEmmanuel Vadot        minItems: 1
63*8d13bc63SEmmanuel Vadot        maxItems: 36
64*8d13bc63SEmmanuel Vadot
65*8d13bc63SEmmanuel Vadot      function:
66*8d13bc63SEmmanuel Vadot        description:
67*8d13bc63SEmmanuel Vadot          Specify the alternative function to be configured for the specified
68*8d13bc63SEmmanuel Vadot          pins.
69*8d13bc63SEmmanuel Vadot        enum: [ gpio, aoss_cti, atest_char, atest_usb, audio_ext_mclk0,
70*8d13bc63SEmmanuel Vadot                audio_ext_mclk1, audio_ref_clk, cam_aon_mclk2, cam_aon_mclk4,
71*8d13bc63SEmmanuel Vadot                cam_mclk, cci_async_in, cci_i2c_scl, cci_i2c_sda, cci_timer,
72*8d13bc63SEmmanuel Vadot                cmu_rng, coex_uart1_rx, coex_uart1_tx, coex_uart2_rx,
73*8d13bc63SEmmanuel Vadot                coex_uart2_tx, cri_trng, dbg_out_clk, ddr_bist_complete,
74*8d13bc63SEmmanuel Vadot                ddr_bist_fail, ddr_bist_start, ddr_bist_stop, ddr_pxi0,
75*8d13bc63SEmmanuel Vadot                ddr_pxi1, ddr_pxi2, ddr_pxi3, do_not, dp_hot, gcc_gp1,
76*8d13bc63SEmmanuel Vadot                gcc_gp2, gcc_gp3, gnss_adc0, gnss_adc1, i2chub0_se0,
77*8d13bc63SEmmanuel Vadot                i2chub0_se1, i2chub0_se2, i2chub0_se3, i2chub0_se4,
78*8d13bc63SEmmanuel Vadot                i2chub0_se5, i2chub0_se6, i2chub0_se7, i2chub0_se8,
79*8d13bc63SEmmanuel Vadot                i2chub0_se9, i2s0_data0, i2s0_data1, i2s0_sck, i2s0_ws,
80*8d13bc63SEmmanuel Vadot                i2s1_data0, i2s1_data1, i2s1_sck, i2s1_ws, ibi_i3c,
81*8d13bc63SEmmanuel Vadot                jitter_bist, mdp_vsync, mdp_vsync0_out, mdp_vsync1_out,
82*8d13bc63SEmmanuel Vadot                mdp_vsync2_out, mdp_vsync3_out, mdp_vsync_e, nav_gpio0,
83*8d13bc63SEmmanuel Vadot                nav_gpio1, nav_gpio2, nav_gpio3, pcie0_clk_req_n,
84*8d13bc63SEmmanuel Vadot                pcie1_clk_req_n, phase_flag, pll_bist_sync, pll_clk_aux,
85*8d13bc63SEmmanuel Vadot                prng_rosc0, prng_rosc1, prng_rosc2, prng_rosc3, qdss_cti,
86*8d13bc63SEmmanuel Vadot                qdss_gpio, qlink_big_enable, qlink_big_request,
87*8d13bc63SEmmanuel Vadot                qlink_little_enable, qlink_little_request, qlink_wmss,
88*8d13bc63SEmmanuel Vadot                qspi0, qspi1, qspi2, qspi3, qspi_clk, qspi_cs, qup1_se0,
89*8d13bc63SEmmanuel Vadot                qup1_se1, qup1_se2, qup1_se3, qup1_se4, qup1_se5, qup1_se6,
90*8d13bc63SEmmanuel Vadot                qup1_se7, qup2_se0, qup2_se1, qup2_se2, qup2_se3, qup2_se4,
91*8d13bc63SEmmanuel Vadot                qup2_se5, qup2_se6, qup2_se7, sd_write_protect, sdc40, sdc41,
92*8d13bc63SEmmanuel Vadot                sdc42, sdc43, sdc4_clk, sdc4_cmd, tb_trig_sdc2, tb_trig_sdc4,
93*8d13bc63SEmmanuel Vadot                tgu_ch0_trigout, tgu_ch1_trigout, tgu_ch2_trigout,
94*8d13bc63SEmmanuel Vadot                tgu_ch3_trigout, tmess_prng0, tmess_prng1, tmess_prng2,
95*8d13bc63SEmmanuel Vadot                tmess_prng3, tsense_pwm1, tsense_pwm2, tsense_pwm3, uim0_clk,
96*8d13bc63SEmmanuel Vadot                uim0_data, uim0_present, uim0_reset, uim1_clk, uim1_data,
97*8d13bc63SEmmanuel Vadot                uim1_present, uim1_reset, usb1_hs, usb_phy, vfr_0, vfr_1,
98*8d13bc63SEmmanuel Vadot                vsense_trigger_mirnat ]
99*8d13bc63SEmmanuel Vadot
100*8d13bc63SEmmanuel Vadot    required:
101*8d13bc63SEmmanuel Vadot      - pins
102*8d13bc63SEmmanuel Vadot
103*8d13bc63SEmmanuel Vadotrequired:
104*8d13bc63SEmmanuel Vadot  - compatible
105*8d13bc63SEmmanuel Vadot  - reg
106*8d13bc63SEmmanuel Vadot
107*8d13bc63SEmmanuel VadotunevaluatedProperties: false
108*8d13bc63SEmmanuel Vadot
109*8d13bc63SEmmanuel Vadotexamples:
110*8d13bc63SEmmanuel Vadot  - |
111*8d13bc63SEmmanuel Vadot    #include <dt-bindings/interrupt-controller/arm-gic.h>
112*8d13bc63SEmmanuel Vadot    tlmm: pinctrl@f100000 {
113*8d13bc63SEmmanuel Vadot        compatible = "qcom,sm8650-tlmm";
114*8d13bc63SEmmanuel Vadot        reg = <0x0f100000 0x300000>;
115*8d13bc63SEmmanuel Vadot        gpio-controller;
116*8d13bc63SEmmanuel Vadot        #gpio-cells = <2>;
117*8d13bc63SEmmanuel Vadot        gpio-ranges = <&tlmm 0 0 211>;
118*8d13bc63SEmmanuel Vadot        interrupt-controller;
119*8d13bc63SEmmanuel Vadot        #interrupt-cells = <2>;
120*8d13bc63SEmmanuel Vadot        interrupts = <GIC_SPI 208 IRQ_TYPE_LEVEL_HIGH>;
121*8d13bc63SEmmanuel Vadot
122*8d13bc63SEmmanuel Vadot        gpio-wo-state {
123*8d13bc63SEmmanuel Vadot            pins = "gpio1";
124*8d13bc63SEmmanuel Vadot            function = "gpio";
125*8d13bc63SEmmanuel Vadot        };
126*8d13bc63SEmmanuel Vadot
127*8d13bc63SEmmanuel Vadot        uart-w-state {
128*8d13bc63SEmmanuel Vadot            rx-pins {
129*8d13bc63SEmmanuel Vadot                pins = "gpio60";
130*8d13bc63SEmmanuel Vadot                function = "qup1_se7";
131*8d13bc63SEmmanuel Vadot                bias-pull-up;
132*8d13bc63SEmmanuel Vadot            };
133*8d13bc63SEmmanuel Vadot
134*8d13bc63SEmmanuel Vadot            tx-pins {
135*8d13bc63SEmmanuel Vadot                pins = "gpio61";
136*8d13bc63SEmmanuel Vadot                function = "qup1_se7";
137*8d13bc63SEmmanuel Vadot                bias-disable;
138*8d13bc63SEmmanuel Vadot            };
139*8d13bc63SEmmanuel Vadot        };
140*8d13bc63SEmmanuel Vadot    };
141*8d13bc63SEmmanuel Vadot...
142