diff options
author | Pramod Gurav <pramod.gurav@smartplayin.com> | 2014-08-30 07:13:00 -0400 |
---|---|---|
committer | Linus Walleij <linus.walleij@linaro.org> | 2014-09-04 12:46:39 -0400 |
commit | 0a5d667048ab3b22dff3c60561a79310981ee897 (patch) | |
tree | c475e61d0f85d0afbded7441de295b27269325f4 /drivers/pinctrl | |
parent | f712c554a7fca8f6308afbce844eacbf5e48787b (diff) |
pinctrl: sirf: Remove gpiochip on failure cases
This patch releases gpiochip related resources by calling
gpiochip_remove when gpiochip_irqchip_add fails.
CC: Linus Walleij <linus.walleij@linaro.org>
CC: Barry Song <Baohua.Song@csr.com>
CC: Rongjun Ying <rongjun.ying@csr.com>
CC: Yuping Luo <yuping.luo@csr.com>
Signed-off-by: Pramod Gurav <pramod.gurav@smartplayin.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/pinctrl')
-rw-r--r-- | drivers/pinctrl/sirf/pinctrl-sirf.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/pinctrl/sirf/pinctrl-sirf.c b/drivers/pinctrl/sirf/pinctrl-sirf.c index 6f252fd7cb0c..b713bd59ffbb 100644 --- a/drivers/pinctrl/sirf/pinctrl-sirf.c +++ b/drivers/pinctrl/sirf/pinctrl-sirf.c | |||
@@ -853,7 +853,7 @@ static int sirfsoc_gpio_probe(struct device_node *np) | |||
853 | if (err) { | 853 | if (err) { |
854 | dev_err(&pdev->dev, | 854 | dev_err(&pdev->dev, |
855 | "could not connect irqchip to gpiochip\n"); | 855 | "could not connect irqchip to gpiochip\n"); |
856 | goto out; | 856 | goto out_banks; |
857 | } | 857 | } |
858 | 858 | ||
859 | for (i = 0; i < SIRFSOC_GPIO_NO_OF_BANKS; i++) { | 859 | for (i = 0; i < SIRFSOC_GPIO_NO_OF_BANKS; i++) { |