]> git.baikalelectronics.ru Git - kernel.git/commit
mmc: core: Don't return an error for CD/WP GPIOs when GPIOLIB is unset
authorUlf Hansson <ulf.hansson@linaro.org>
Mon, 14 Sep 2015 10:18:55 +0000 (12:18 +0200)
committerUlf Hansson <ulf.hansson@linaro.org>
Tue, 29 Sep 2015 10:17:03 +0000 (12:17 +0200)
commit93a353f78a6f782f811664302948ef5442bfd2a7
tree7806d6f79352391d8eab40eba3c1f918825a2d2a
parent755b54c2d7664b903bfb45b7d15cb67261530d08
mmc: core: Don't return an error for CD/WP GPIOs when GPIOLIB is unset

When CONFIG_GPIOLIB is unset, its stubs will return -ENOSYS. That means
when the mmc core parses DT for CD/WP GPIOs via mmc_of_parse(), -ENOSYS
becomes propagated to the caller. Typically this means that the mmc host
driver fails to probe.

As the CD/WP GPIOs are already treated as optional, let's extend that to
cover the case when CONFIG_GPIOLIB is unset.

Reported-by: Michal Simek <michal.simek@xilinx.com>
Fixes: 6b70147a33a8 ("mmc: sdhci-of-arasan: Call OF parsing for MMC")
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Tested-by: Michal Simek <michal.simek@xilinx.com>
Acked-by: Venu Byravarasu <vbyravarasu@nvidia.com>
drivers/mmc/core/host.c