diff options
author | abdoulaye berthe <berthe.ab@gmail.com> | 2014-07-12 22:30:14 +0200 |
---|---|---|
committer | Linus Walleij <linus.walleij@linaro.org> | 2014-09-18 11:03:10 -0700 |
commit | 88d5e520aa9701eb3e4f46165e02097cc03d363a (patch) | |
tree | 443b8f89eeaf8933a9d3af2c9928cf0008aa35fd /drivers/mfd/sm501.c | |
parent | 2134cb997f2f1b2d960ad8705d67dc8d690ba59c (diff) |
driver:gpio remove all usage of gpio_remove retval in driver
this remove all reference to gpio_remove retval in all driver
except pinctrl and gpio. the same thing is done for gpio and
pinctrl in two different patches.
Signed-off-by: Abdoulaye Berthe <berthe.ab@gmail.com>
Acked-by: Michael Büsch <m@bues.ch>
Acked-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Acked-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
Acked-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/mfd/sm501.c')
-rw-r--r-- | drivers/mfd/sm501.c | 17 |
1 files changed, 3 insertions, 14 deletions
diff --git a/drivers/mfd/sm501.c b/drivers/mfd/sm501.c index 81e6d0932bf0..02027b7f1223 100644 --- a/drivers/mfd/sm501.c +++ b/drivers/mfd/sm501.c @@ -1047,7 +1047,6 @@ static int sm501_register_gpio(struct sm501_devdata *sm) struct sm501_gpio *gpio = &sm->gpio; resource_size_t iobase = sm->io_res->start + SM501_GPIO; int ret; - int tmp; dev_dbg(sm->dev, "registering gpio block %08llx\n", (unsigned long long)iobase); @@ -1086,11 +1085,7 @@ static int sm501_register_gpio(struct sm501_devdata *sm) return 0; err_low_chip: - tmp = gpiochip_remove(&gpio->low.gpio); - if (tmp) { - dev_err(sm->dev, "cannot remove low chip, cannot tidy up\n"); - return ret; - } + gpiochip_remove(&gpio->low.gpio); err_mapped: iounmap(gpio->regs); @@ -1105,18 +1100,12 @@ static int sm501_register_gpio(struct sm501_devdata *sm) static void sm501_gpio_remove(struct sm501_devdata *sm) { struct sm501_gpio *gpio = &sm->gpio; - int ret; if (!sm->gpio.registered) return; - ret = gpiochip_remove(&gpio->low.gpio); - if (ret) - dev_err(sm->dev, "cannot remove low chip, cannot tidy up\n"); - - ret = gpiochip_remove(&gpio->high.gpio); - if (ret) - dev_err(sm->dev, "cannot remove high chip, cannot tidy up\n"); + gpiochip_remove(&gpio->low.gpio); + gpiochip_remove(&gpio->high.gpio); iounmap(gpio->regs); release_resource(gpio->regs_res); |