Merge branch 'master' of git://git.denx.de/u-boot-usb
[oweals/u-boot.git] / drivers / mmc / omap_hsmmc.c
index ef64e37411f235dfb9b21ac6c719e1a9f5b07c8c..2400db2f35671df76a6b9e8bb927e1438f397b58 100644 (file)
@@ -198,9 +198,10 @@ static int mmc_send_cmd(struct mmc *mmc, struct mmc_cmd *cmd,
        ulong start;
 
        start = get_timer(0);
-       while ((readl(&mmc_base->pstate) & DATI_MASK) == DATI_CMDDIS) {
+       while ((readl(&mmc_base->pstate) & (DATI_MASK | CMDI_MASK)) != 0) {
                if (get_timer(0) - start > MAX_RETRY_MS) {
-                       printf("%s: timedout waiting for cmddis!\n", __func__);
+                       printf("%s: timedout waiting on cmd inhibit to clear\n",
+                                       __func__);
                        return TIMEOUT;
                }
        }