]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
drivers/gpio/it8761e_gpio: check return value of gpiochip_remove()
authorDaniel Mack <daniel@caiaq.de>
Wed, 26 May 2010 21:42:26 +0000 (14:42 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Thu, 27 May 2010 16:12:42 +0000 (09:12 -0700)
This eliminates the following build warning:

drivers/gpio/it8761e_gpio.c: In function `it8761e_gpio_exit':
drivers/gpio/it8761e_gpio.c:220: warning: ignoring return value of `gpiochip_remove', declared with attribute warn_unused_result

Signed-off-by: Daniel Mack <daniel@caiaq.de>
Cc: Denis Turischev <denis@compulab.co.il>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
drivers/gpio/it8761e_gpio.c

index 41a9388f2fde03917455e77a9d18149ba3f292dc..48fc43c4bdd11fc2849a2273fcdf10e98267cc91 100644 (file)
@@ -217,7 +217,10 @@ gpiochip_add_err:
 static void __exit it8761e_gpio_exit(void)
 {
        if (gpio_ba) {
-               gpiochip_remove(&it8761e_gpio_chip);
+               int ret = gpiochip_remove(&it8761e_gpio_chip);
+
+               WARN(ret, "%s(): gpiochip_remove() failed, ret=%d\n",
+                               __func__, ret);
 
                release_region(gpio_ba, GPIO_IOSIZE);
                gpio_ba = 0;