Skip to content

Commit 1c378a4

Browse files
andredlag-linaro
authored andcommitted
mfd: max77759: Drop use of irqd_get_trigger_type
irqd_get_trigger_type() is meant for cases where the driver needs to know the configured IRQ trigger type and e.g. wants to change its behaviour accordingly. Furthermore, platform support code, e.g. DT handling, will configure the hardware based on that, and drivers don't need to pass the trigger type into request_irq() and friends. Drop the use from this driver, as it doesn't need to know the trigger type. Signed-off-by: André Draszik <andre.draszik@linaro.org> Link: https://patch.msgid.link/20251217-max77759-mfd-irq-trigger-v1-1-e7d29f84d34f@linaro.org Signed-off-by: Lee Jones <lee@kernel.org>
1 parent 0ec4122 commit 1c378a4

1 file changed

Lines changed: 1 addition & 11 deletions

File tree

drivers/mfd/max77759.c

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -587,9 +587,7 @@ static int max77759_add_chained_charger(struct i2c_client *client,
587587
static int max77759_probe(struct i2c_client *client)
588588
{
589589
struct regmap_irq_chip_data *irq_chip_data_pmic;
590-
struct irq_data *irq_data;
591590
struct max77759 *max77759;
592-
unsigned long irq_flags;
593591
unsigned int pmic_id;
594592
int ret;
595593

@@ -628,16 +626,8 @@ static int max77759_probe(struct i2c_client *client)
628626
return ret;
629627
}
630628

631-
irq_data = irq_get_irq_data(client->irq);
632-
if (!irq_data)
633-
return dev_err_probe(&client->dev, -EINVAL,
634-
"invalid IRQ: %d\n", client->irq);
635-
636-
irq_flags = IRQF_ONESHOT | IRQF_SHARED;
637-
irq_flags |= irqd_get_trigger_type(irq_data);
638-
639629
ret = devm_regmap_add_irq_chip(&client->dev, max77759->regmap_top,
640-
client->irq, irq_flags, 0,
630+
client->irq, IRQF_ONESHOT | IRQF_SHARED, 0,
641631
&max77759_pmic_irq_chip,
642632
&irq_chip_data_pmic);
643633
if (ret)

0 commit comments

Comments
 (0)