summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorBo Shen <voice.shen@atmel.com>2013-04-26 00:27:07 +0000
committerAndreas Bießmann <andreas.devel@googlemail.com>2013-05-12 16:48:11 +0200
commit93e3236ccbd37369ed309bef5d77761e63d1759c (patch)
treefe1b2bb66a4d32440e9d2ae0b6dfb530023e81c6 /drivers
parentaac4b69b2c916736911976562bfc0cb4bfd26b2f (diff)
downloadu-boot-imx-93e3236ccbd37369ed309bef5d77761e63d1759c.zip
u-boot-imx-93e3236ccbd37369ed309bef5d77761e63d1759c.tar.gz
u-boot-imx-93e3236ccbd37369ed309bef5d77761e63d1759c.tar.bz2
mmc: atmel_mci: add mmc card support
add mmc card support with atmel mci driver Signed-off-by: Bo Shen <voice.shen@atmel.com> Signed-off-by: Andreas Bießmann <andreas.devel@googlemail.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/mmc/gen_atmel_mci.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/mmc/gen_atmel_mci.c b/drivers/mmc/gen_atmel_mci.c
index fc0a181..77ebf17 100644
--- a/drivers/mmc/gen_atmel_mci.c
+++ b/drivers/mmc/gen_atmel_mci.c
@@ -211,7 +211,10 @@ mci_send_cmd(struct mmc *mmc, struct mmc_cmd *cmd, struct mmc_data *data)
/* Wait for the command to complete */
while (!((status = readl(&mci->sr)) & MMCI_BIT(CMDRDY)));
- if (status & error_flags) {
+ if ((status & error_flags) & MMCI_BIT(RTOE)) {
+ dump_cmd(cmdr, cmd->cmdarg, status, "Command Time Out");
+ return TIMEOUT;
+ } else if (status & error_flags) {
dump_cmd(cmdr, cmd->cmdarg, status, "Command Failed");
return COMM_ERR;
}