diff mbox series

Input: adxl34x - do not hardcode interrupt trigger type

Message ID 20230509203555.549158-1-marex@denx.de
State Accepted
Commit e96220bce5176ed2309f77f061dcc0430b82b25e
Headers show
Series Input: adxl34x - do not hardcode interrupt trigger type | expand

Commit Message

Marek Vasut May 9, 2023, 8:35 p.m. UTC
Instead of hardcoding IRQ trigger type to IRQF_TRIGGER_HIGH, let's
respect the settings specified in the firmware description.

Fixes: e27c729219ad2 ("Input: add driver for ADXL345/346 Digital Accelerometers")
Signed-off-by: Marek Vasut <marex@denx.de>
---
Cc: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Cc: Michael Hennerich <michael.hennerich@analog.com>
Cc: linux-input@vger.kernel.org
---
 drivers/input/misc/adxl34x.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

Comments

Dmitry Torokhov May 11, 2023, 12:28 a.m. UTC | #1
On Tue, May 09, 2023 at 10:35:55PM +0200, Marek Vasut wrote:
> Instead of hardcoding IRQ trigger type to IRQF_TRIGGER_HIGH, let's
> respect the settings specified in the firmware description.
> 
> Fixes: e27c729219ad2 ("Input: add driver for ADXL345/346 Digital Accelerometers")
> Signed-off-by: Marek Vasut <marex@denx.de>

Applied, thank you.
diff mbox series

Patch

diff --git a/drivers/input/misc/adxl34x.c b/drivers/input/misc/adxl34x.c
index eecca671b5884..a3f45e0ee0c75 100644
--- a/drivers/input/misc/adxl34x.c
+++ b/drivers/input/misc/adxl34x.c
@@ -817,8 +817,7 @@  struct adxl34x *adxl34x_probe(struct device *dev, int irq,
 	AC_WRITE(ac, POWER_CTL, 0);
 
 	err = request_threaded_irq(ac->irq, NULL, adxl34x_irq,
-				   IRQF_TRIGGER_HIGH | IRQF_ONESHOT,
-				   dev_name(dev), ac);
+				   IRQF_ONESHOT, dev_name(dev), ac);
 	if (err) {
 		dev_err(dev, "irq %d busy?\n", ac->irq);
 		goto err_free_mem;