Commit b6f87adb authored by Bartosz Golaszewski's avatar Bartosz Golaszewski

gpio: remove unneeded code from gpio_device_get_desc()

The GPIO chip pointer is unused. Let's remove it.
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 2559f2e0
......@@ -184,16 +184,6 @@ EXPORT_SYMBOL_GPL(gpiochip_get_desc);
struct gpio_desc *
gpio_device_get_desc(struct gpio_device *gdev, unsigned int hwnum)
{
struct gpio_chip *gc;
/*
* FIXME: This will be locked once we protect gdev->chip everywhere
* with SRCU.
*/
gc = gdev->chip;
if (!gc)
return ERR_PTR(-ENODEV);
if (hwnum >= gdev->ngpio)
return ERR_PTR(-EINVAL);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment