Input: gpio_keys - add device tree support for interrupt only keys
[sfrench/cifs-2.6.git] / Documentation / devicetree / bindings / input / gpio-keys.txt
index 5c2c02140a62dac132566aaeb4f6156b46233f41..a4a38fcf2ed61d1fa3db42e053fb8259f2ffcc71 100644 (file)
@@ -10,10 +10,13 @@ Optional properties:
 Each button (key) is represented as a sub-node of "gpio-keys":
 Subnode properties:
 
-       - gpios: OF device-tree gpio specification.
        - label: Descriptive name of the key.
        - linux,code: Keycode to emit.
 
+Required mutual exclusive subnode-properties:
+       - gpios: OF device-tree gpio specification.
+       - interrupts: the interrupt line for that input
+
 Optional subnode-properties:
        - linux,input-type: Specify event type this button/key generates.
          If not specified defaults to <1> == EV_KEY.
@@ -33,4 +36,9 @@ Example nodes:
                                linux,code = <103>;
                                gpios = <&gpio1 0 1>;
                        };
+                       button@22 {
+                               label = "GPIO Key DOWN";
+                               linux,code = <108>;
+                               interrupts = <1 IRQ_TYPE_LEVEL_HIGH 7>;
+                       };
                        ...