2
0
mirror of https://github.com/edk2-porting/linux-next.git synced 2024-12-23 04:34:11 +08:00

gpio: grgpio: remove irq_domain resources on failure

Call irq_domain_remove when gpiochip_add fails to release irq_domain
resources.

Signed-off-by: Pramod Gurav <pramod.gurav@smartplayin.com>
Acked-by: Alexandre Courbot <acourbot@nvidia.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
This commit is contained in:
Pramod Gurav 2014-10-02 00:08:04 +05:30 committed by Linus Walleij
parent 1972c97db5
commit 65fdc966c0

View File

@ -441,6 +441,7 @@ static int grgpio_probe(struct platform_device *ofdev)
err = gpiochip_add(gc);
if (err) {
dev_err(&ofdev->dev, "Could not add gpiochip\n");
irq_domain_remove(priv->domain);
return err;
}