mmc: Implement card detection.

Check for card detect each time an MMC/SD device is initialized. If card
detection is not implemented, this code behaves as before and continues
assuming a card is present. If no card is detected, has_init is reset
for the MMC/SD device (to force initialization next time) and an error
is returned.

Signed-off-by: Thierry Reding <thierry.reding@avionic-design.de>
Tested-by: Jason Liu <jason.hui@linaro.org>
diff --git a/drivers/mmc/sdhci.c b/drivers/mmc/sdhci.c
index fce0ef0..fc904b5 100644
--- a/drivers/mmc/sdhci.c
+++ b/drivers/mmc/sdhci.c
@@ -390,6 +390,7 @@
 	mmc->send_cmd = sdhci_send_command;
 	mmc->set_ios = sdhci_set_ios;
 	mmc->init = sdhci_init;
+	mmc->getcd = NULL;
 
 	caps = sdhci_readl(host, SDHCI_CAPABILITIES);
 #ifdef CONFIG_MMC_SDMA