aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/gpio/gpio-ml-ioh.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/drivers/gpio/gpio-ml-ioh.c b/drivers/gpio/gpio-ml-ioh.c
index 74fdce096c26..4b80e996d976 100644
--- a/drivers/gpio/gpio-ml-ioh.c
+++ b/drivers/gpio/gpio-ml-ioh.c
@@ -391,9 +391,10 @@ static int ioh_gpio_alloc_generic_chip(struct ioh_gpio *chip,
391{ 391{
392 struct irq_chip_generic *gc; 392 struct irq_chip_generic *gc;
393 struct irq_chip_type *ct; 393 struct irq_chip_type *ct;
394 int rv;
394 395
395 gc = irq_alloc_generic_chip("ioh_gpio", 1, irq_start, chip->base, 396 gc = devm_irq_alloc_generic_chip(chip->dev, "ioh_gpio", 1, irq_start,
396 handle_simple_irq); 397 chip->base, handle_simple_irq);
397 if (!gc) 398 if (!gc)
398 return -ENOMEM; 399 return -ENOMEM;
399 400
@@ -406,10 +407,11 @@ static int ioh_gpio_alloc_generic_chip(struct ioh_gpio *chip,
406 ct->chip.irq_disable = ioh_irq_disable; 407 ct->chip.irq_disable = ioh_irq_disable;
407 ct->chip.irq_enable = ioh_irq_enable; 408 ct->chip.irq_enable = ioh_irq_enable;
408 409
409 irq_setup_generic_chip(gc, IRQ_MSK(num), IRQ_GC_INIT_MASK_CACHE, 410 rv = devm_irq_setup_generic_chip(chip->dev, gc, IRQ_MSK(num),
410 IRQ_NOREQUEST | IRQ_NOPROBE, 0); 411 IRQ_GC_INIT_MASK_CACHE,
412 IRQ_NOREQUEST | IRQ_NOPROBE, 0);
411 413
412 return 0; 414 return rv;
413} 415}
414 416
415static int ioh_gpio_probe(struct pci_dev *pdev, 417static int ioh_gpio_probe(struct pci_dev *pdev,