bmips: vr-3032u: fix gpio keys
[openwrt/staging/chunkeey.git] / target / linux / bmips / patches-5.10 / 400-Documentation-add-BCM6328-pincontroller-binding-docu.patch
1 From 3b6d70e7bae0dbba02435c53f878a042d6d4bd4d Mon Sep 17 00:00:00 2001
2 From: =?UTF-8?q?=C3=81lvaro=20Fern=C3=A1ndez=20Rojas?= <noltari@gmail.com>
3 Date: Wed, 27 Jul 2016 11:33:56 +0200
4 Subject: [PATCH 01/12] Documentation: add BCM6328 pincontroller binding
5 documentation
6 MIME-Version: 1.0
7 Content-Type: text/plain; charset=UTF-8
8 Content-Transfer-Encoding: 8bit
9
10 Add binding documentation for the pincontrol core found in BCM6328 SoCs.
11
12 Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
13 Signed-off-by: Jonas Gorski <jonas.gorski@gmail.com>
14 ---
15 .../pinctrl/brcm,bcm6328-pinctrl.yaml | 161 ++++++++++++++++++
16 1 file changed, 161 insertions(+)
17 create mode 100644 Documentation/devicetree/bindings/pinctrl/brcm,bcm6328-pinctrl.yaml
18
19 --- /dev/null
20 +++ b/Documentation/devicetree/bindings/pinctrl/brcm,bcm6328-pinctrl.yaml
21 @@ -0,0 +1,161 @@
22 +# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
23 +%YAML 1.2
24 +---
25 +$id: http://devicetree.org/schemas/pinctrl/brcm,bcm6328-pinctrl.yaml#
26 +$schema: http://devicetree.org/meta-schemas/core.yaml#
27 +
28 +title: Broadcom BCM6328 pin controller
29 +
30 +maintainers:
31 + - Álvaro Fernández Rojas <noltari@gmail.com>
32 + - Jonas Gorski <jonas.gorski@gmail.com>
33 +
34 +description: |+
35 + The pin controller node should be the child of a syscon node.
36 +
37 + Refer to the the bindings described in
38 + Documentation/devicetree/bindings/mfd/syscon.yaml
39 +
40 +properties:
41 + compatible:
42 + const: brcm,bcm6328-pinctrl
43 +
44 + gpio-controller: true
45 +
46 + '#gpio-cells':
47 + description:
48 + Specifies the pin number and flags, as defined in
49 + include/dt-bindings/gpio/gpio.h
50 + const: 2
51 +
52 + interrupts-extended:
53 + description:
54 + One interrupt per each of the 4 GPIO ports supported by the controller,
55 + sorted by port number ascending order.
56 + minItems: 4
57 + maxItems: 4
58 +
59 +patternProperties:
60 + '^.*$':
61 + if:
62 + type: object
63 + then:
64 + properties:
65 + function:
66 + $ref: "/schemas/types.yaml#/definitions/string"
67 + enum: [ serial_led_data, serial_led_clk, inet_act_led, pcie_clkreq,
68 + led, ephy0_act_led, ephy1_act_led, ephy2_act_led,
69 + ephy3_act_led, hsspi_cs1, usb_device_port, usb_host_port ]
70 +
71 + pins:
72 + $ref: "/schemas/types.yaml#/definitions/string"
73 + enum: [ gpio6, gpio7, gpio11, gpio16, gpio17, gpio18, gpio19,
74 + gpio20, gpio25, gpio26, gpio27, gpio28, hsspi_cs1,
75 + usb_port1 ]
76 +
77 +required:
78 + - compatible
79 + - gpio-controller
80 + - '#gpio-cells'
81 +
82 +additionalProperties: false
83 +
84 +examples:
85 + - |
86 + gpio@10000080 {
87 + compatible = "syscon", "simple-mfd";
88 + reg = <0x10000080 0x80>;
89 +
90 + pinctrl: pinctrl {
91 + compatible = "brcm,bcm6328-pinctrl";
92 +
93 + gpio-controller;
94 + #gpio-cells = <2>;
95 +
96 + interrupts-extended = <&ext_intc 3 0>,
97 + <&ext_intc 2 0>,
98 + <&ext_intc 1 0>,
99 + <&ext_intc 0 0>;
100 + interrupt-names = "gpio12",
101 + "gpio15",
102 + "gpio23",
103 + "gpio24";
104 +
105 + pinctrl_serial_led: serial_led {
106 + pinctrl_serial_led_data: serial_led_data {
107 + function = "serial_led_data";
108 + pins = "gpio6";
109 + };
110 +
111 + pinctrl_serial_led_clk: serial_led_clk {
112 + function = "serial_led_clk";
113 + pins = "gpio7";
114 + };
115 + };
116 +
117 + pinctrl_inet_act_led: inet_act_led {
118 + function = "inet_act_led";
119 + pins = "gpio11";
120 + };
121 +
122 + pinctrl_pcie_clkreq: pcie_clkreq {
123 + function = "pcie_clkreq";
124 + pins = "gpio16";
125 + };
126 +
127 + pinctrl_ephy0_spd_led: ephy0_spd_led {
128 + function = "led";
129 + pins = "gpio17";
130 + };
131 +
132 + pinctrl_ephy1_spd_led: ephy1_spd_led {
133 + function = "led";
134 + pins = "gpio18";
135 + };
136 +
137 + pinctrl_ephy2_spd_led: ephy2_spd_led {
138 + function = "led";
139 + pins = "gpio19";
140 + };
141 +
142 + pinctrl_ephy3_spd_led: ephy3_spd_led {
143 + function = "led";
144 + pins = "gpio20";
145 + };
146 +
147 + pinctrl_ephy0_act_led: ephy0_act_led {
148 + function = "ephy0_act_led";
149 + pins = "gpio25";
150 + };
151 +
152 + pinctrl_ephy1_act_led: ephy1_act_led {
153 + function = "ephy1_act_led";
154 + pins = "gpio26";
155 + };
156 +
157 + pinctrl_ephy2_act_led: ephy2_act_led {
158 + function = "ephy2_act_led";
159 + pins = "gpio27";
160 + };
161 +
162 + pinctrl_ephy3_act_led: ephy3_act_led {
163 + function = "ephy3_act_led";
164 + pins = "gpio28";
165 + };
166 +
167 + pinctrl_hsspi_cs1: hsspi_cs1 {
168 + function = "hsspi_cs1";
169 + pins = "hsspi_cs1";
170 + };
171 +
172 + pinctrl_usb_port1_device: usb_port1_device {
173 + function = "usb_device_port";
174 + pins = "usb_port1";
175 + };
176 +
177 + pinctrl_usb_port1_host: usb_port1_host {
178 + function = "usb_host_port";
179 + pins = "usb_port1";
180 + };
181 + };
182 + };