Commit e488fed0 authored by Hans de Goede's avatar Hans de Goede Committed by Jonathan Cameron

iio: accel: bmc150: Removed unused bmc150_accel_dat irq member

The bmc150_accel_dat struct irq member is only ever used inside
bmc150_accel_core_probe, drop it and just use the function argument
directly.
Signed-off-by: default avatarHans de Goede <hdegoede@redhat.com>
Reviewed-by: default avatarAndy Shevchenko <andy.shevchenko@gmail.com>
Link: https://lore.kernel.org/r/20201130141954.339805-1-hdegoede@redhat.comSigned-off-by: default avatarJonathan Cameron <Jonathan.Cameron@huawei.com>
parent 26aec6e1
...@@ -186,7 +186,6 @@ enum bmc150_accel_trigger_id { ...@@ -186,7 +186,6 @@ enum bmc150_accel_trigger_id {
struct bmc150_accel_data { struct bmc150_accel_data {
struct regmap *regmap; struct regmap *regmap;
struct regulator_bulk_data regulators[2]; struct regulator_bulk_data regulators[2];
int irq;
struct bmc150_accel_interrupt interrupts[BMC150_ACCEL_INTERRUPTS]; struct bmc150_accel_interrupt interrupts[BMC150_ACCEL_INTERRUPTS];
struct bmc150_accel_trigger triggers[BMC150_ACCEL_TRIGGERS]; struct bmc150_accel_trigger triggers[BMC150_ACCEL_TRIGGERS];
struct mutex mutex; struct mutex mutex;
...@@ -1582,7 +1581,6 @@ int bmc150_accel_core_probe(struct device *dev, struct regmap *regmap, int irq, ...@@ -1582,7 +1581,6 @@ int bmc150_accel_core_probe(struct device *dev, struct regmap *regmap, int irq,
data = iio_priv(indio_dev); data = iio_priv(indio_dev);
dev_set_drvdata(dev, indio_dev); dev_set_drvdata(dev, indio_dev);
data->irq = irq;
data->regmap = regmap; data->regmap = regmap;
...@@ -1645,9 +1643,8 @@ int bmc150_accel_core_probe(struct device *dev, struct regmap *regmap, int irq, ...@@ -1645,9 +1643,8 @@ int bmc150_accel_core_probe(struct device *dev, struct regmap *regmap, int irq,
goto err_disable_regulators; goto err_disable_regulators;
} }
if (data->irq > 0) { if (irq > 0) {
ret = devm_request_threaded_irq( ret = devm_request_threaded_irq(dev, irq,
dev, data->irq,
bmc150_accel_irq_handler, bmc150_accel_irq_handler,
bmc150_accel_irq_thread_handler, bmc150_accel_irq_thread_handler,
IRQF_TRIGGER_RISING, IRQF_TRIGGER_RISING,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment