Skip to content
  • Martin Kepplinger's avatar
    iio: mma8452: support either of the available interrupt pins · d2a3e093
    Martin Kepplinger authored
    
    
    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: default avatarMartin Kepplinger <martin.kepplinger@theobroma-systems.com>
    For the binding: Acked-by: Rob Herring <robh@kernel.org>
    Signed-off-by: default avatarJonathan Cameron <jic23@kernel.org>
    d2a3e093