gpiolib: Implement devm_gpio_request_one()
authorMark Brown <broonie@opensource.wolfsonmicro.com>
Wed, 2 May 2012 11:46:46 +0000 (12:46 +0100)
committerGrant Likely <grant.likely@secretlab.ca>
Fri, 18 May 2012 22:48:35 +0000 (16:48 -0600)
commit09d71ff19404b3957fab6de942fb8026ccfd8524
treeba3680f5b79ea1fbeae073ab7cb28c9bdcad7e60
parenteb1567f7ad0032ba7b02b878e352f191d53dc228
gpiolib: Implement devm_gpio_request_one()

Allow drivers to use the modern request and configure idiom together
with devres.

As with plain gpio_request() and gpio_request_one() we can't implement
the old school version in terms of _one() as this would force the
explicit selection of a direction in gpio_request() which could break
systems if we pick the wrong one.  Implementing devm_gpio_request_one()
in terms of devm_gpio_request() would needlessly complicate things or
lead to duplication from the unmanaged version depending on how it's
done.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
drivers/gpio/devres.c
include/asm-generic/gpio.h
include/linux/gpio.h