Commit f6aa01c2 authored by Rabin Vincent's avatar Rabin Vincent Committed by Russell King

ARM: 6177/1: nomadik-gpio: fix "ignoring return value" warning

arch/arm/plat-nomadik/gpio.c: In function 'nmk_gpio_remove':
arch/arm/plat-nomadik/gpio.c:630: warning: ignoring return value of 'gpiochip_remove', declared with attribute warn_unused_result

Because this function is marked __exit and this code can't be built as a
module, this function is never used.  So just remove it, fixing the
warning in the process.
Acked-by: default avatarAlessandro Rubini <rubini@unipv.it>
Acked-by: default avatarLinus Walleij <linus.walleij@stericsson.com>
Signed-off-by: default avatarRabin Vincent <rabin.vincent@stericsson.com>
Signed-off-by: default avatarRussell King <rmk+kernel@arm.linux.org.uk>
parent 0d2aec9c
...@@ -619,30 +619,12 @@ static int __init nmk_gpio_probe(struct platform_device *dev) ...@@ -619,30 +619,12 @@ static int __init nmk_gpio_probe(struct platform_device *dev)
return ret; return ret;
} }
static int __exit nmk_gpio_remove(struct platform_device *dev)
{
struct nmk_gpio_chip *nmk_chip;
struct resource *res;
res = platform_get_resource(dev, IORESOURCE_MEM, 0);
nmk_chip = platform_get_drvdata(dev);
gpiochip_remove(&nmk_chip->chip);
clk_disable(nmk_chip->clk);
clk_put(nmk_chip->clk);
kfree(nmk_chip);
release_mem_region(res->start, resource_size(res));
return 0;
}
static struct platform_driver nmk_gpio_driver = { static struct platform_driver nmk_gpio_driver = {
.driver = { .driver = {
.owner = THIS_MODULE, .owner = THIS_MODULE,
.name = "gpio", .name = "gpio",
}, },
.probe = nmk_gpio_probe, .probe = nmk_gpio_probe,
.remove = __exit_p(nmk_gpio_remove),
.suspend = NULL, /* to be done */ .suspend = NULL, /* to be done */
.resume = NULL, .resume = NULL,
}; };
......
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