Re: [PATCH] pinctrl: remove remaining users of gpiochip_remove() retval

From: Arnd Bergmann
Date: Fri Sep 26 2014 - 16:41:42 EST


On Wednesday 17 September 2014, Linus Walleij wrote:
> Some drivers accidentally still use the return value from
> gpiochip_remove(). Get rid of them so we can simplify this function
> and get rid of the return value.
>
> Cc: Abdoulaye Berthe <berthe.ab@xxxxxxxxx>
> Signed-off-by: Linus Walleij <linus.walleij@xxxxxxxxxx>
> ---
> This patch will be merged through the GPIO tree.

Hi Linus, this patch caused a new build warning in some configurations:

> diff --git a/drivers/pinctrl/nomadik/pinctrl-abx500.c b/drivers/pinctrl/nomadik/pinctrl-abx500.c
> index a53a689a2bfa..7df34b70e8b6 100644
> --- a/drivers/pinctrl/nomadik/pinctrl-abx500.c
> +++ b/drivers/pinctrl/nomadik/pinctrl-abx500.c
> @@ -1298,10 +1298,7 @@ static int abx500_gpio_probe(struct platform_device *pdev)
> return 0;
>
> out_rem_chip:
> - err = gpiochip_remove(&pct->chip);
> - if (err)
> - dev_info(&pdev->dev, "failed to remove gpiochip\n");
> -
> + gpiochip_remove(&pct->chip);
> return ret;
> }


drivers/pinctrl/nomadik/pinctrl-abx500.c: In function 'abx500_gpio_probe':
drivers/pinctrl/nomadik/pinctrl-abx500.c:1208:11: warning: unused variable 'err' [-Wunused-variable]

Please fix by removing that variable.

Arnd
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/