1Broadcom BCM2835 GPIO (and pinmux) controller 2 3The BCM2835 GPIO module is a combined GPIO controller, (GPIO) interrupt 4controller, and pinmux/control device. 5 6Required properties: 7- compatible: "brcm,bcm2835-gpio" 8- reg: Should contain the physical address of the GPIO module's registers. 9- gpio-controller: Marks the device node as a GPIO controller. 10- #gpio-cells : Should be two. The first cell is the pin number and the 11 second cell is used to specify optional parameters: 12 - bit 0 specifies polarity (0 for normal, 1 for inverted) 13- interrupts : The interrupt outputs from the controller. One interrupt per 14 individual bank followed by the "all banks" interrupt. 15- interrupt-controller: Marks the device node as an interrupt controller. 16- #interrupt-cells : Should be 2. 17 The first cell is the GPIO number. 18 The second cell is used to specify flags: 19 bits[3:0] trigger type and level flags: 20 1 = low-to-high edge triggered. 21 2 = high-to-low edge triggered. 22 4 = active high level-sensitive. 23 8 = active low level-sensitive. 24 Valid combinations are 1, 2, 3, 4, 8. 25 26Please refer to ../gpio/gpio.txt for a general description of GPIO bindings. 27 28Please refer to pinctrl-bindings.txt in this directory for details of the 29common pinctrl bindings used by client devices, including the meaning of the 30phrase "pin configuration node". 31 32Each pin configuration node lists the pin(s) to which it applies, and one or 33more of the mux function to select on those pin(s), and pull-up/down 34configuration. Each subnode only affects those parameters that are explicitly 35listed. In other words, a subnode that lists only a mux function implies no 36information about any pull configuration. Similarly, a subnode that lists only 37a pul parameter implies no information about the mux function. 38 39The BCM2835 pin configuration and multiplexing supports the generic bindings. 40For details on each properties, you can refer to ./pinctrl-bindings.txt. 41 42Required sub-node properties: 43 - pins 44 - function 45 46Optional sub-node properties: 47 - bias-disable 48 - bias-pull-up 49 - bias-pull-down 50 - output-high 51 - output-low 52 53Legacy pin configuration and multiplexing binding: 54*** (Its use is deprecated, use generic multiplexing and configuration 55bindings instead) 56 57Required subnode-properties: 58- brcm,pins: An array of cells. Each cell contains the ID of a pin. Valid IDs 59 are the integer GPIO IDs; 0==GPIO0, 1==GPIO1, ... 53==GPIO53. 60 61Optional subnode-properties: 62- brcm,function: Integer, containing the function to mux to the pin(s): 63 0: GPIO in 64 1: GPIO out 65 2: alt5 66 3: alt4 67 4: alt0 68 5: alt1 69 6: alt2 70 7: alt3 71- brcm,pull: Integer, representing the pull-down/up to apply to the pin(s): 72 0: none 73 1: down 74 2: up 75 76Each of brcm,function and brcm,pull may contain either a single value which 77will be applied to all pins in brcm,pins, or 1 value for each entry in 78brcm,pins. 79 80Example: 81 82 gpio: gpio { 83 compatible = "brcm,bcm2835-gpio"; 84 reg = <0x2200000 0xb4>; 85 interrupts = <2 17>, <2 19>, <2 18>, <2 20>; 86 87 gpio-controller; 88 #gpio-cells = <2>; 89 90 interrupt-controller; 91 #interrupt-cells = <2>; 92 }; 93