]> 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)
commitb33b0044611f6a8d355fd8d8a9b82c6dae69e27d
tree080558048b5ea99f1efbfe4368387440ea30d673
parentaf5c7008dae4002c344ca5c9a3f5f61de17c7f32
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