summaryrefslogtreecommitdiffstats
path: root/dts/Bindings/gpio/gpio-adnp.txt
diff options
context:
space:
mode:
Diffstat (limited to 'dts/Bindings/gpio/gpio-adnp.txt')
-rw-r--r--dts/Bindings/gpio/gpio-adnp.txt34
1 files changed, 34 insertions, 0 deletions
diff --git a/dts/Bindings/gpio/gpio-adnp.txt b/dts/Bindings/gpio/gpio-adnp.txt
new file mode 100644
index 0000000000..af66b27248
--- /dev/null
+++ b/dts/Bindings/gpio/gpio-adnp.txt
@@ -0,0 +1,34 @@
+Avionic Design N-bit GPIO expander bindings
+
+Required properties:
+- compatible: should be "ad,gpio-adnp"
+- reg: The I2C slave address for this device.
+- interrupt-parent: phandle of the parent interrupt controller.
+- interrupts: Interrupt specifier for the controllers interrupt.
+- #gpio-cells: Should be 2. The first cell is the GPIO number and the
+ second cell is used to specify optional parameters:
+ - bit 0: polarity (0: normal, 1: inverted)
+- gpio-controller: Marks the device as a GPIO controller
+- nr-gpios: The number of pins supported by the controller.
+
+The GPIO expander can optionally be used as an interrupt controller, in
+which case it uses the default two cell specifier as described in
+Documentation/devicetree/bindings/interrupt-controller/interrupts.txt.
+
+Example:
+
+ gpioext: gpio-controller@41 {
+ compatible = "ad,gpio-adnp";
+ reg = <0x41>;
+
+ interrupt-parent = <&gpio>;
+ interrupts = <160 1>;
+
+ gpio-controller;
+ #gpio-cells = <2>;
+
+ interrupt-controller;
+ #interrupt-cells = <2>;
+
+ nr-gpios = <64>;
+ };