gpiolib: devres: fix devm_gpiod_get_index()

Fix the return value if devm_gpiod_get_index(). It was returning 0 while
it should return the obtained GPIO descriptor.

Signed-off-by: Alexandre Courbot <acourbot@nvidia.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
This commit is contained in:
Alexandre Courbot 2013-10-20 15:14:57 -07:00 committed by Linus Walleij
parent 45f394391f
commit 5fcdb9dc98
1 changed files with 1 additions and 1 deletions

View File

@ -80,7 +80,7 @@ struct gpio_desc *__must_check devm_gpiod_get_index(struct device *dev,
*dr = desc;
devres_add(dev, dr);
return 0;
return desc;
}
EXPORT_SYMBOL(devm_gpiod_get_index);