Commit 7fe595b3 authored by Bartosz Golaszewski's avatar Bartosz Golaszewski
Browse files

gpio: don't dereference gdev->chip in gpiochip_setup_dev()



We don't need to dereference gdev->chip in gpiochip_setup_dev() as at
the time it's called, the label in the associated struct gpio_device is
already set.

Signed-off-by: default avatarBartosz Golaszewski <bartosz.golaszewski@linaro.org>
Reviewed-by: default avatarLinus Walleij <linus.walleij@linaro.org>
Acked-by: default avatarAndy Shevchenko <andriy.shevchenko@linux.intel.com>
parent 5694f274
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -723,7 +723,7 @@ static int gpiochip_setup_dev(struct gpio_device *gdev)
		goto err_remove_device;

	dev_dbg(&gdev->dev, "registered GPIOs %d to %d on %s\n", gdev->base,
		gdev->base + gdev->ngpio - 1, gdev->chip->label ? : "generic");
		gdev->base + gdev->ngpio - 1, gdev->label);

	return 0;