xref: /openbmc/linux/Documentation/devicetree/bindings/gpio/raspberrypi,firmware-gpio.txt (revision c13aca79ff3c4af5fd31a5b2743a90eba6e36a26)
1*9777d809SBaruch SiachRaspberry Pi GPIO expander
2*9777d809SBaruch Siach
3*9777d809SBaruch SiachThe Raspberry Pi 3 GPIO expander is controlled by the VC4 firmware. The
4*9777d809SBaruch Siachfirmware exposes a mailbox interface that allows the ARM core to control the
5*9777d809SBaruch SiachGPIO lines on the expander.
6*9777d809SBaruch Siach
7*9777d809SBaruch SiachThe Raspberry Pi GPIO expander node must be a child node of the Raspberry Pi
8*9777d809SBaruch Siachfirmware node.
9*9777d809SBaruch Siach
10*9777d809SBaruch SiachRequired properties:
11*9777d809SBaruch Siach
12*9777d809SBaruch Siach- compatible : Should be "raspberrypi,firmware-gpio"
13*9777d809SBaruch Siach- gpio-controller : Marks the device node as a gpio controller
14*9777d809SBaruch Siach- #gpio-cells : Should be two.  The first cell is the pin number, and
15*9777d809SBaruch Siach  the second cell is used to specify the gpio polarity:
16*9777d809SBaruch Siach  0 = active high
17*9777d809SBaruch Siach  1 = active low
18*9777d809SBaruch Siach
19*9777d809SBaruch SiachExample:
20*9777d809SBaruch Siach
21*9777d809SBaruch Siachfirmware: firmware-rpi {
22*9777d809SBaruch Siach	compatible = "raspberrypi,bcm2835-firmware";
23*9777d809SBaruch Siach	mboxes = <&mailbox>;
24*9777d809SBaruch Siach
25*9777d809SBaruch Siach	expgpio: gpio {
26*9777d809SBaruch Siach		 compatible = "raspberrypi,firmware-gpio";
27*9777d809SBaruch Siach		 gpio-controller;
28*9777d809SBaruch Siach		 #gpio-cells = <2>;
29*9777d809SBaruch Siach	 };
30*9777d809SBaruch Siach};
31