Tom Rini | 53633a8 | 2024-02-29 12:33:36 -0500 | [diff] [blame] | 1 | Qualcomm APQ8064 TLMM block |
| 2 | |
| 3 | Required properties: |
| 4 | - compatible: "qcom,apq8064-pinctrl" |
| 5 | - reg: Should be the base address and length of the TLMM block. |
| 6 | - interrupts: Should be the parent IRQ of the TLMM block. |
| 7 | - interrupt-controller: Marks the device node as an interrupt controller. |
| 8 | - #interrupt-cells: Should be two. |
| 9 | - gpio-controller: Marks the device node as a GPIO controller. |
| 10 | - #gpio-cells : Should be two. |
| 11 | The first cell is the gpio pin number and the |
| 12 | second cell is used for optional parameters. |
| 13 | - gpio-ranges: see ../gpio/gpio.txt |
| 14 | |
| 15 | Optional properties: |
| 16 | |
| 17 | - gpio-reserved-ranges: see ../gpio/gpio.txt |
| 18 | |
| 19 | Please refer to ../gpio/gpio.txt and ../interrupt-controller/interrupts.txt for |
| 20 | a general description of GPIO and interrupt bindings. |
| 21 | |
| 22 | Please refer to pinctrl-bindings.txt in this directory for details of the |
| 23 | common pinctrl bindings used by client devices, including the meaning of the |
| 24 | phrase "pin configuration node". |
| 25 | |
| 26 | Qualcomm's pin configuration nodes act as a container for an arbitrary number of |
| 27 | subnodes. Each of these subnodes represents some desired configuration for a |
| 28 | pin, a group, or a list of pins or groups. This configuration can include the |
| 29 | mux function to select on those pin(s)/group(s), and various pin configuration |
| 30 | parameters, such as pull-up, drive strength, etc. |
| 31 | |
| 32 | The name of each subnode is not important; all subnodes should be enumerated |
| 33 | and processed purely based on their content. |
| 34 | |
| 35 | Each subnode only affects those parameters that are explicitly listed. In |
| 36 | other words, a subnode that lists a mux function but no pin configuration |
| 37 | parameters implies no information about any pin configuration parameters. |
| 38 | Similarly, a pin subnode that describes a pullup parameter implies no |
| 39 | information about e.g. the mux function. |
| 40 | |
| 41 | |
| 42 | The following generic properties as defined in pinctrl-bindings.txt are valid |
| 43 | to specify in a pin configuration subnode: |
| 44 | |
| 45 | pins, function, bias-disable, bias-pull-down, bias-pull-up, drive-strength, |
| 46 | output-low, output-high. |
| 47 | |
| 48 | Non-empty subnodes must specify the 'pins' property. |
| 49 | |
| 50 | Valid values for pins are: |
| 51 | gpio0-gpio89 |
| 52 | |
| 53 | Valid values for function are: |
| 54 | cam_mclk, codec_mic_i2s, codec_spkr_i2s, gp_clk_0a, gp_clk_0b, gp_clk_1a, |
| 55 | gp_clk_1b, gp_clk_2a, gp_clk_2b, gpio, gsbi1, gsbi2, gsbi3, gsbi4, |
| 56 | gsbi4_cam_i2c, gsbi5, gsbi5_spi_cs1, gsbi5_spi_cs2, gsbi5_spi_cs3, gsbi6, |
| 57 | gsbi6_spi_cs1, gsbi6_spi_cs2, gsbi6_spi_cs3, gsbi7, gsbi7_spi_cs1, |
| 58 | gsbi7_spi_cs2, gsbi7_spi_cs3, gsbi_cam_i2c, hdmi, mi2s, riva_bt, riva_fm, |
| 59 | riva_wlan, sdc2, sdc4, slimbus, spkr_i2s, tsif1, tsif2, usb2_hsic, ps_hold |
| 60 | |
| 61 | Example: |
| 62 | |
| 63 | msmgpio: pinctrl@800000 { |
| 64 | compatible = "qcom,apq8064-pinctrl"; |
| 65 | reg = <0x800000 0x4000>; |
| 66 | |
| 67 | gpio-controller; |
| 68 | #gpio-cells = <2>; |
| 69 | interrupt-controller; |
| 70 | #interrupt-cells = <2>; |
| 71 | interrupts = <0 16 0x4>; |
| 72 | |
| 73 | pinctrl-names = "default"; |
| 74 | pinctrl-0 = <&gsbi5_uart_default>; |
| 75 | gpio-ranges = <&msmgpio 0 0 90>; |
| 76 | |
| 77 | gsbi5_uart_default: gsbi5_uart_default { |
| 78 | mux { |
| 79 | pins = "gpio51", "gpio52"; |
| 80 | function = "gsbi5"; |
| 81 | }; |
| 82 | |
| 83 | tx { |
| 84 | pins = "gpio51"; |
| 85 | drive-strength = <4>; |
| 86 | bias-disable; |
| 87 | }; |
| 88 | |
| 89 | rx { |
| 90 | pins = "gpio52"; |
| 91 | drive-strength = <2>; |
| 92 | bias-pull-up; |
| 93 | }; |
| 94 | }; |
| 95 | }; |