diff options
author | Jonathan Cameron <Jonathan.Cameron@huawei.com> | 2024-09-01 14:59:48 +0100 |
---|---|---|
committer | Jonathan Cameron <Jonathan.Cameron@huawei.com> | 2024-09-30 09:20:59 +0100 |
commit | a9facbf521e7b02b2123ae141fc21ff273ebacf3 (patch) | |
tree | b918abd736ff84cfd6e1aafcd2e413085fcd60cc | |
parent | e200fa767f2301a5ee39bc6c17d576a18965f6df (diff) | |
download | lwn-a9facbf521e7b02b2123ae141fc21ff273ebacf3.tar.gz lwn-a9facbf521e7b02b2123ae141fc21ff273ebacf3.zip |
iio: light: st_uvis25: use irq_get_trigger_type()
Use irq_get_trigger_type() to replace getting the irq data then the
type in two steps.
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Reviewed-by: Lorenzo Bianconi <lorenzo@kernel.org>
Link: https://patch.msgid.link/20240901135950.797396-14-jic23@kernel.org
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-rw-r--r-- | drivers/iio/light/st_uvis25_core.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/iio/light/st_uvis25_core.c b/drivers/iio/light/st_uvis25_core.c index fba3997574bb..f1fc8cb6f69a 100644 --- a/drivers/iio/light/st_uvis25_core.c +++ b/drivers/iio/light/st_uvis25_core.c @@ -174,8 +174,7 @@ static int st_uvis25_allocate_trigger(struct iio_dev *iio_dev) unsigned long irq_type; int err; - irq_type = irqd_get_trigger_type(irq_get_irq_data(hw->irq)); - + irq_type = irq_get_trigger_type(hw->irq); switch (irq_type) { case IRQF_TRIGGER_HIGH: case IRQF_TRIGGER_RISING: |