diff options
author | Pramod Gurav <pramod.gurav@smartplayin.com> | 2014-10-01 14:38:04 -0400 |
---|---|---|
committer | Linus Walleij <linus.walleij@linaro.org> | 2014-10-28 11:11:19 -0400 |
commit | 65fdc966c012b62ce4da5bf8175140a9b2ec2ee7 (patch) | |
tree | 4588632c8e78a4bd5895f2e82efb86b46fb2df0f /drivers/gpio/gpio-grgpio.c | |
parent | 1972c97db5b0c125918f662cd084c7d5370674c0 (diff) |
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>
Diffstat (limited to 'drivers/gpio/gpio-grgpio.c')
-rw-r--r-- | drivers/gpio/gpio-grgpio.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/gpio/gpio-grgpio.c b/drivers/gpio/gpio-grgpio.c index 66ad3df9d9cf..38acdcea9799 100644 --- a/drivers/gpio/gpio-grgpio.c +++ b/drivers/gpio/gpio-grgpio.c | |||
@@ -441,6 +441,7 @@ static int grgpio_probe(struct platform_device *ofdev) | |||
441 | err = gpiochip_add(gc); | 441 | err = gpiochip_add(gc); |
442 | if (err) { | 442 | if (err) { |
443 | dev_err(&ofdev->dev, "Could not add gpiochip\n"); | 443 | dev_err(&ofdev->dev, "Could not add gpiochip\n"); |
444 | irq_domain_remove(priv->domain); | ||
444 | return err; | 445 | return err; |
445 | } | 446 | } |
446 | 447 | ||