From: Alan Cox Date: Tue, 24 Jul 2012 12:55:10 +0000 (+0100) Subject: gpio-sch: Fix leak of resource X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=8abdd2d2d873ece35a201c2e05af7b6998cf0dca;p=openwrt%2Fstaging%2Fblogic.git gpio-sch: Fix leak of resource Signed-off-by: Alan Cox Signed-off-by: Linus Walleij --- diff --git a/drivers/gpio/gpio-sch.c b/drivers/gpio/gpio-sch.c index 424dce8e3f30..8707d4572a06 100644 --- a/drivers/gpio/gpio-sch.c +++ b/drivers/gpio/gpio-sch.c @@ -241,7 +241,8 @@ static int __devinit sch_gpio_probe(struct platform_device *pdev) break; default: - return -ENODEV; + err = -ENODEV; + goto err_sch_gpio_core; } sch_gpio_core.dev = &pdev->dev;