mmc: sdhci: Allow override of get_cd() called from sdhci_request()
authorAdrian Hunter <adrian.hunter@intel.com>
Tue, 9 Feb 2016 14:12:36 +0000 (16:12 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 3 Mar 2016 23:07:16 +0000 (15:07 -0800)
commit61b9408bfd06779c8b2073829bf2f73a81531a99
treea664b5137e48011ebea200858251518acf7182bd
parentbafb71422d791e7c074dadbab5bf8e421a1ef97b
mmc: sdhci: Allow override of get_cd() called from sdhci_request()

commit 8d28b7a72fe18bcdcdb047243ba8fec36b149955 upstream.

Drivers may need to provide their own get_cd() mmc host op, but
currently the internals of the current op (sdhci_get_cd()) are
provided by sdhci_do_get_cd() which is also called from
sdhci_request().

To allow override of the get_cd functionality, change sdhci_request()
to call ->get_cd() instead of sdhci_do_get_cd().

Note, in the future the call to ->get_cd() will likely be removed
from sdhci_request() since most drivers don't need actually it.
However this change is being done now to facilitate a subsequent
bug fix.

Signed-off-by: Adrian Hunter <adrian.hunter@intel.com>
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/mmc/host/sdhci.c