xref: /freebsd/sys/contrib/device-tree/Bindings/pinctrl/qcom,sm8350-pinctrl.yaml (revision 7ef62cebc2f965b0f640263e179276928885e33d)
15def4c47SEmmanuel Vadot# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
25def4c47SEmmanuel Vadot%YAML 1.2
35def4c47SEmmanuel Vadot---
45def4c47SEmmanuel Vadot$id: http://devicetree.org/schemas/pinctrl/qcom,sm8350-pinctrl.yaml#
55def4c47SEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml#
65def4c47SEmmanuel Vadot
75def4c47SEmmanuel Vadottitle: Qualcomm Technologies, Inc. SM8350 TLMM block
85def4c47SEmmanuel Vadot
95def4c47SEmmanuel Vadotmaintainers:
105def4c47SEmmanuel Vadot  - Vinod Koul <vkoul@kernel.org>
115def4c47SEmmanuel Vadot
125def4c47SEmmanuel Vadotdescription: |
135def4c47SEmmanuel Vadot  This binding describes the Top Level Mode Multiplexer (TLMM) block found
145def4c47SEmmanuel Vadot  in the SM8350 platform.
155def4c47SEmmanuel Vadot
165def4c47SEmmanuel VadotallOf:
17e67e8565SEmmanuel Vadot  - $ref: "pinctrl.yaml#"
185def4c47SEmmanuel Vadot  - $ref: /schemas/pinctrl/qcom,tlmm-common.yaml#
195def4c47SEmmanuel Vadot
205def4c47SEmmanuel Vadotproperties:
215def4c47SEmmanuel Vadot  compatible:
225def4c47SEmmanuel Vadot    const: qcom,sm8350-tlmm
235def4c47SEmmanuel Vadot
245def4c47SEmmanuel Vadot  reg:
255def4c47SEmmanuel Vadot    maxItems: 1
265def4c47SEmmanuel Vadot
275def4c47SEmmanuel Vadot  interrupts: true
285def4c47SEmmanuel Vadot  interrupt-controller: true
295def4c47SEmmanuel Vadot  '#interrupt-cells': true
305def4c47SEmmanuel Vadot  gpio-controller: true
315def4c47SEmmanuel Vadot  gpio-reserved-ranges: true
325def4c47SEmmanuel Vadot  '#gpio-cells': true
335def4c47SEmmanuel Vadot  gpio-ranges: true
345def4c47SEmmanuel Vadot  wakeup-parent: true
355def4c47SEmmanuel Vadot
365def4c47SEmmanuel Vadotrequired:
375def4c47SEmmanuel Vadot  - compatible
385def4c47SEmmanuel Vadot  - reg
395def4c47SEmmanuel Vadot
405def4c47SEmmanuel VadotadditionalProperties: false
415def4c47SEmmanuel Vadot
425def4c47SEmmanuel VadotpatternProperties:
435def4c47SEmmanuel Vadot  '-state$':
445def4c47SEmmanuel Vadot    oneOf:
455def4c47SEmmanuel Vadot      - $ref: "#/$defs/qcom-sm8350-tlmm-state"
465def4c47SEmmanuel Vadot      - patternProperties:
47*7ef62cebSEmmanuel Vadot          "-pins$":
485def4c47SEmmanuel Vadot            $ref: "#/$defs/qcom-sm8350-tlmm-state"
49*7ef62cebSEmmanuel Vadot        additionalProperties: false
505def4c47SEmmanuel Vadot
515def4c47SEmmanuel Vadot$defs:
525def4c47SEmmanuel Vadot  qcom-sm8350-tlmm-state:
535def4c47SEmmanuel Vadot    type: object
545def4c47SEmmanuel Vadot    description:
555def4c47SEmmanuel Vadot      Pinctrl node's client devices use subnodes for desired pin configuration.
565def4c47SEmmanuel Vadot      Client device subnodes use below standard properties.
575def4c47SEmmanuel Vadot
585def4c47SEmmanuel Vadot    properties:
595def4c47SEmmanuel Vadot      pins:
605def4c47SEmmanuel Vadot        description:
615def4c47SEmmanuel Vadot          List of gpio pins affected by the properties specified in this
625def4c47SEmmanuel Vadot          subnode.
635def4c47SEmmanuel Vadot        items:
645def4c47SEmmanuel Vadot          oneOf:
655def4c47SEmmanuel Vadot            - pattern: "^gpio([0-9]|[1-9][0-9]|1[0-9][0-9]|20[0-3])$"
665def4c47SEmmanuel Vadot            - enum: [ sdc1_clk, sdc1_cmd, sdc1_data, sdc2_clk, sdc2_cmd, sdc2_data ]
675def4c47SEmmanuel Vadot        minItems: 1
685def4c47SEmmanuel Vadot        maxItems: 36
695def4c47SEmmanuel Vadot
705def4c47SEmmanuel Vadot      function:
715def4c47SEmmanuel Vadot        description:
725def4c47SEmmanuel Vadot          Specify the alternative function to be configured for the specified
735def4c47SEmmanuel Vadot          pins.
745def4c47SEmmanuel Vadot
755def4c47SEmmanuel Vadot        enum: [ atest_char, atest_usb, audio_ref, cam_mclk, cci_async,
765def4c47SEmmanuel Vadot                cci_i2c, cci_timer, cmu_rng, coex_uart1, coex_uart2, cri_trng,
775def4c47SEmmanuel Vadot                cri_trng0, cri_trng1, dbg_out, ddr_bist, ddr_pxi0, ddr_pxi1,
785def4c47SEmmanuel Vadot                ddr_pxi2, ddr_pxi3, dp_hot, dp_lcd, gcc_gp1, gcc_gp2, gcc_gp3,
795def4c47SEmmanuel Vadot                gpio, ibi_i3c, jitter_bist, lpass_slimbus, mdp_vsync, mdp_vsync0,
805def4c47SEmmanuel Vadot                mdp_vsync1, mdp_vsync2, mdp_vsync3, mi2s0_data0, mi2s0_data1,
815def4c47SEmmanuel Vadot                mi2s0_sck, mi2s0_ws, mi2s1_data0, mi2s1_data1, mi2s1_sck,
825def4c47SEmmanuel Vadot                mi2s1_ws, mi2s2_data0, mi2s2_data1, mi2s2_sck, mi2s2_ws,
835def4c47SEmmanuel Vadot                mss_grfc0, mss_grfc1, mss_grfc10, mss_grfc11, mss_grfc12,
845def4c47SEmmanuel Vadot                mss_grfc2, mss_grfc3, mss_grfc4, mss_grfc5, mss_grfc6,
855def4c47SEmmanuel Vadot                mss_grfc7, mss_grfc8, mss_grfc9, nav_gpio, pa_indicator,
865def4c47SEmmanuel Vadot                pcie0_clkreqn, pcie1_clkreqn, phase_flag, pll_bist, pll_clk,
875def4c47SEmmanuel Vadot                pri_mi2s, prng_rosc, qdss_cti, qdss_gpio, qlink0_enable,
885def4c47SEmmanuel Vadot                qlink0_request, qlink0_wmss, qlink1_enable, qlink1_request,
895def4c47SEmmanuel Vadot                qlink1_wmss, qlink2_enable, qlink2_request, qlink2_wmss, qspi0,
905def4c47SEmmanuel Vadot                qspi1, qspi2, qspi3, qspi_clk, qspi_cs, qup0, qup1, qup10,
915def4c47SEmmanuel Vadot                qup11, qup12, qup13, qup14, qup15, qup16, qup17, qup18, qup19,
925def4c47SEmmanuel Vadot                qup2, qup3, qup4, qup5, qup6, qup7, qup8, qup9, qup_l4, qup_l5,
935def4c47SEmmanuel Vadot                qup_l6, sd_write, sdc40, sdc41, sdc42, sdc43, sdc4_clk,
945def4c47SEmmanuel Vadot                sdc4_cmd, sec_mi2s, tb_trig, tgu_ch0, tgu_ch1, tgu_ch2,
955def4c47SEmmanuel Vadot                tgu_ch3, tsense_pwm1, tsense_pwm2, uim0_clk, uim0_data,
965def4c47SEmmanuel Vadot                uim0_present, uim0_reset, uim1_clk, uim1_data, uim1_present,
975def4c47SEmmanuel Vadot                uim1_reset, usb2phy_ac, usb_phy, vfr_0, vfr_1, vsense_trigger ]
985def4c47SEmmanuel Vadot
995def4c47SEmmanuel Vadot
1005def4c47SEmmanuel Vadot      bias-disable: true
1015def4c47SEmmanuel Vadot      bias-pull-down: true
1025def4c47SEmmanuel Vadot      bias-pull-up: true
1035def4c47SEmmanuel Vadot      drive-strength: true
1045def4c47SEmmanuel Vadot      input-enable: true
1055def4c47SEmmanuel Vadot      output-high: true
1065def4c47SEmmanuel Vadot      output-low: true
1075def4c47SEmmanuel Vadot
1085def4c47SEmmanuel Vadot    required:
1095def4c47SEmmanuel Vadot      - pins
110*7ef62cebSEmmanuel Vadot
111*7ef62cebSEmmanuel Vadot    allOf:
112*7ef62cebSEmmanuel Vadot      - $ref: "qcom,tlmm-common.yaml#/$defs/qcom-tlmm-state"
113*7ef62cebSEmmanuel Vadot      - if:
114*7ef62cebSEmmanuel Vadot          properties:
115*7ef62cebSEmmanuel Vadot            pins:
116*7ef62cebSEmmanuel Vadot              pattern: "^gpio([0-9]|[1-9][0-9]|1[0-9][0-9]|20[0-3])$"
117*7ef62cebSEmmanuel Vadot        then:
118*7ef62cebSEmmanuel Vadot          required:
1195def4c47SEmmanuel Vadot            - function
1205def4c47SEmmanuel Vadot
1215def4c47SEmmanuel Vadot    additionalProperties: false
1225def4c47SEmmanuel Vadot
1235def4c47SEmmanuel Vadotexamples:
1245def4c47SEmmanuel Vadot  - |
1255def4c47SEmmanuel Vadot    #include <dt-bindings/interrupt-controller/arm-gic.h>
1265def4c47SEmmanuel Vadot    pinctrl@f100000 {
1275def4c47SEmmanuel Vadot        compatible = "qcom,sm8350-tlmm";
1285def4c47SEmmanuel Vadot        reg = <0x0f100000 0x300000>;
1295def4c47SEmmanuel Vadot        interrupts = <GIC_SPI 208 IRQ_TYPE_LEVEL_HIGH>;
1305def4c47SEmmanuel Vadot        gpio-controller;
1315def4c47SEmmanuel Vadot        #gpio-cells = <2>;
1325def4c47SEmmanuel Vadot        interrupt-controller;
1335def4c47SEmmanuel Vadot        #interrupt-cells = <2>;
1345def4c47SEmmanuel Vadot        gpio-ranges = <&tlmm 0 0 203>;
1355def4c47SEmmanuel Vadot
1365def4c47SEmmanuel Vadot        gpio-wo-subnode-state {
1375def4c47SEmmanuel Vadot            pins = "gpio1";
1385def4c47SEmmanuel Vadot            function = "gpio";
1395def4c47SEmmanuel Vadot        };
1405def4c47SEmmanuel Vadot
1415def4c47SEmmanuel Vadot        uart-w-subnodes-state {
142*7ef62cebSEmmanuel Vadot            rx-pins {
1435def4c47SEmmanuel Vadot                pins = "gpio18";
1445def4c47SEmmanuel Vadot                function = "qup3";
1455def4c47SEmmanuel Vadot                bias-pull-up;
1465def4c47SEmmanuel Vadot            };
1475def4c47SEmmanuel Vadot
148*7ef62cebSEmmanuel Vadot            tx-pins {
1495def4c47SEmmanuel Vadot                pins = "gpio19";
1505def4c47SEmmanuel Vadot                function = "qup3";
1515def4c47SEmmanuel Vadot                bias-disable;
1525def4c47SEmmanuel Vadot            };
1535def4c47SEmmanuel Vadot        };
1545def4c47SEmmanuel Vadot    };
1555def4c47SEmmanuel Vadot...
156