drivers: adxl362: use Kconfig for interrupt mode

Commit 11295c1 added Kconfig options for interrupt mode, but then hard
coded the interrupt mode. This commit uses the Kconfig option to set
the interrupt mode.

Applications expecting the interrupt mode to be something other than
the default will need to be updated.

Signed-off-by: Brett Witherspoon <spoonb@cdspooner.com>
This commit is contained in:
Brett Witherspoon 2019-05-08 10:00:11 -05:00 committed by Maureen Helm
commit cddb3a1e34

View file

@ -154,8 +154,7 @@ int adxl362_init_interrupt(struct device *dev)
return -EINVAL;
}
/* Configures the inactivity and activity interrupts to be linked. */
ret = adxl362_set_interrupt_mode(dev, ADXL362_MODE_LINK);
ret = adxl362_set_interrupt_mode(dev, CONFIG_ADXL362_INTERRUPT_MODE);
if (ret) {
return -EFAULT;