diff options
author | Yangbo Lu <yangbo.lu@freescale.com> | 2015-04-22 05:57:00 (GMT) |
---|---|---|
committer | York Sun <yorksun@freescale.com> | 2015-05-04 16:25:19 (GMT) |
commit | 5a8dbdc6b4b8b4b17c807c9bb23807cdc66f6feb (patch) | |
tree | 13de7d43ebb84d211debe354937bcf1b8701c2f8 /drivers/mmc/mmc.c | |
parent | fd3a78a538b2591a420f173faea442ae969ff623 (diff) | |
download | u-boot-5a8dbdc6b4b8b4b17c807c9bb23807cdc66f6feb.tar.xz |
mmc: fsl_esdhc: Add adapter card type identification support
Add adapter card type identification support by reading
FPGA STAT_PRES1 register SDHC Card ID[0:2] bits. To use this function,
define CONFIG_FSL_ESDHC_ADAPTER_IDENT.
Signed-off-by: Yangbo Lu <yangbo.lu@freescale.com>
Cc: York Sun <yorksun@freescale.com>
Cc: Pantelis Antoniou <panto@antoniou-consulting.com>
[York Sun: resolve conflicts in README.fsl-esdhc]
Reviewed-by: York Sun <yorksun@freescale.com>
Diffstat (limited to 'drivers/mmc/mmc.c')
-rw-r--r-- | drivers/mmc/mmc.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/mmc/mmc.c b/drivers/mmc/mmc.c index a13769e..dc32aec 100644 --- a/drivers/mmc/mmc.c +++ b/drivers/mmc/mmc.c @@ -1588,6 +1588,9 @@ int mmc_start_init(struct mmc *mmc) if (mmc->has_init) return 0; +#ifdef CONFIG_FSL_ESDHC_ADAPTER_IDENT + mmc_adapter_card_type_ident(); +#endif board_mmc_power_init(); /* made sure it's not NULL earlier */ @@ -1739,6 +1742,9 @@ static void do_preinit(void) list_for_each(entry, &mmc_devices) { m = list_entry(entry, struct mmc, link); +#ifdef CONFIG_FSL_ESDHC_ADAPTER_IDENT + mmc_set_preinit(m, 1); +#endif if (m->preinit) mmc_start_init(m); } |