From: Rickard Strandqvist Date: Thu, 26 Jun 2014 16:18:51 +0000 (+0200) Subject: gpio: gpio-ucb1400.c: Cleaning up null pointer checks that could never happen X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=31a3f9da4e2d6a58d562aea608edab79c48bec34;p=GitHub%2FLineageOS%2FG12%2Fandroid_kernel_amlogic_linux-4.9.git gpio: gpio-ucb1400.c: Cleaning up null pointer checks that could never happen Removal of null pointer checks that could never happen This was found using a static code analysis program called cppcheck Signed-off-by: Rickard Strandqvist Signed-off-by: Linus Walleij --- diff --git a/drivers/gpio/gpio-ucb1400.c b/drivers/gpio/gpio-ucb1400.c index 2445fe771179..d520dc9ed709 100644 --- a/drivers/gpio/gpio-ucb1400.c +++ b/drivers/gpio/gpio-ucb1400.c @@ -70,7 +70,7 @@ static int ucb1400_gpio_probe(struct platform_device *dev) if (err) goto err; - if (ucb && ucb->gpio_setup) + if (ucb->gpio_setup) err = ucb->gpio_setup(&dev->dev, ucb->gc.ngpio); err: