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