Commit 4d84b9e4 authored by Geert Uytterhoeven's avatar Geert Uytterhoeven Committed by Linus Walleij

gpio: rcar: Use local variable gpio_chip in gpio_rcar_probe()

The existing variable gpio_chip already points to the gpiochip instance,
hence use it everywhere.
Signed-off-by: default avatarGeert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
parent e189ca56
...@@ -413,7 +413,7 @@ static int gpio_rcar_probe(struct platform_device *pdev) ...@@ -413,7 +413,7 @@ static int gpio_rcar_probe(struct platform_device *pdev)
goto err0; goto err0;
} }
ret = gpiochip_irqchip_add(&p->gpio_chip, irq_chip, p->config.irq_base, ret = gpiochip_irqchip_add(gpio_chip, irq_chip, p->config.irq_base,
handle_level_irq, IRQ_TYPE_NONE); handle_level_irq, IRQ_TYPE_NONE);
if (ret) { if (ret) {
dev_err(dev, "cannot add irqchip\n"); dev_err(dev, "cannot add irqchip\n");
...@@ -431,7 +431,7 @@ static int gpio_rcar_probe(struct platform_device *pdev) ...@@ -431,7 +431,7 @@ static int gpio_rcar_probe(struct platform_device *pdev)
/* warn in case of mismatch if irq base is specified */ /* warn in case of mismatch if irq base is specified */
if (p->config.irq_base) { if (p->config.irq_base) {
ret = irq_find_mapping(p->gpio_chip.irqdomain, 0); ret = irq_find_mapping(gpio_chip->irqdomain, 0);
if (p->config.irq_base != ret) if (p->config.irq_base != ret)
dev_warn(dev, "irq base mismatch (%u/%u)\n", dev_warn(dev, "irq base mismatch (%u/%u)\n",
p->config.irq_base, ret); p->config.irq_base, ret);
...@@ -447,7 +447,7 @@ static int gpio_rcar_probe(struct platform_device *pdev) ...@@ -447,7 +447,7 @@ static int gpio_rcar_probe(struct platform_device *pdev)
return 0; return 0;
err1: err1:
gpiochip_remove(&p->gpio_chip); gpiochip_remove(gpio_chip);
err0: err0:
pm_runtime_put(dev); pm_runtime_put(dev);
pm_runtime_disable(dev); pm_runtime_disable(dev);
......
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