]> git.baikalelectronics.ru Git - kernel.git/commit
mmc: host: sdhci-s3c: Use devm_gpio_request to request GPIOs
authorTomasz Figa <t.figa@samsung.com>
Sun, 25 Nov 2012 20:40:44 +0000 (15:40 -0500)
committerChris Ball <cjb@laptop.org>
Thu, 6 Dec 2012 18:55:00 +0000 (13:55 -0500)
commit2a805d038c43a2bdf39a06da62cba8097d5b5a72
tree080558048b5ea99f1efbfe4368387440ea30d673
parentd8a266693941004e14aa9da916198587c681fbdb
mmc: host: sdhci-s3c: Use devm_gpio_request to request GPIOs

The set of GPIO pins used by sdhci-s3c driver varies between
configurations, such as card detect method, pinctrl availability, etc.
This overly complicates the code requesting and freeing GPIO pins, which
must check which pins are used, when freeing them.

This patch modifies the sdhci-s3c driver to use devm_gpio_request to
free requested pins automatically after unbinding the driver.

Signed-off-by: Tomasz Figa <t.figa@samsung.com>
Acked-by: Thomas Abraham <thomas.abraham@linaro.org>
Signed-off-by: Chris Ball <cjb@laptop.org>
drivers/mmc/host/sdhci-s3c.c