diff options
author | Martin Kepplinger <martink@posteo.de> | 2015-10-15 15:10:32 +0200 |
---|---|---|
committer | Jonathan Cameron <jic23@kernel.org> | 2015-10-25 11:02:42 +0000 |
commit | d2a3e0931a8f3b95b910096d022ffd98adbd075c (patch) | |
tree | f7625c8d23263741bdc4524d541decb531283bcf /Documentation/devicetree/bindings/iio | |
parent | c3af8a28f43315fc46753465a4e77e5619dd9f30 (diff) | |
download | op-kernel-dev-d2a3e0931a8f3b95b910096d022ffd98adbd075c.zip op-kernel-dev-d2a3e0931a8f3b95b910096d022ffd98adbd075c.tar.gz |
iio: mma8452: support either of the available interrupt pins
This change is important in order for everyone to be easily able to use the
driver for one of the supported accelerometer chips!
Until now, the driver blindly assumed that the INT1 interrupt line is wired
on a user's board. But these devices have 2 interrupt lines and can route
their interrupt sources to one of them. Now, if "INT2" is found and matches
i2c_client->irq, INT2 will be used.
The chip's default actually is INT2, which is why probably many boards will
have it wired and can make use of this.
Of course, this also falls back to assuming INT1, so for existing users
nothing will break. The new functionality is described in the bindings doc.
Signed-off-by: Martin Kepplinger <martin.kepplinger@theobroma-systems.com>
For the binding: Acked-by: Rob Herring <robh@kernel.org>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
Diffstat (limited to 'Documentation/devicetree/bindings/iio')
-rw-r--r-- | Documentation/devicetree/bindings/iio/accel/mma8452.txt | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/Documentation/devicetree/bindings/iio/accel/mma8452.txt b/Documentation/devicetree/bindings/iio/accel/mma8452.txt index e3c3746..3c10e85 100644 --- a/Documentation/devicetree/bindings/iio/accel/mma8452.txt +++ b/Documentation/devicetree/bindings/iio/accel/mma8452.txt @@ -7,13 +7,18 @@ Required properties: * "fsl,mma8453" * "fsl,mma8652" * "fsl,mma8653" + - reg: the I2C address of the chip Optional properties: - interrupt-parent: should be the phandle for the interrupt controller + - interrupts: interrupt mapping for GPIO IRQ + - interrupt-names: should contain "INT1" and/or "INT2", the accelerometer's + interrupt line in use. + Example: mma8453fc@1d { @@ -21,4 +26,5 @@ Example: reg = <0x1d>; interrupt-parent = <&gpio1>; interrupts = <5 0>; + interrupt-names = "INT2"; }; |