diff options
Diffstat (limited to 'drivers/mmc/core/core.c')
-rw-r--r-- | drivers/mmc/core/core.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/drivers/mmc/core/core.c b/drivers/mmc/core/core.c index ddd6d50..8252d44 100644 --- a/drivers/mmc/core/core.c +++ b/drivers/mmc/core/core.c @@ -275,12 +275,22 @@ static void mmc_wait_for_req_done(struct mmc_host *host, /* if card is mmc type and nonremovable, and there are erros after issuing r/w command, then init eMMC and mshc */ +#ifdef CONFIG_WIMAX_CMC + if (((host->card) && mmc_card_mmc(host->card) && \ + (host->caps & MMC_CAP_NONREMOVABLE)) && \ + (mrq->cmd->error == -ENOTRECOVERABLE || \ + ((mrq->cmd->opcode == 17 || mrq->cmd->opcode == 18 || \ + mrq->cmd->opcode == 24 || mrq->cmd->opcode == 25) && \ + ((mrq->data->error) || mrq->cmd->error || \ + (mrq->sbc && mrq->sbc->error))))) { +#else if (((host->card) && mmc_card_mmc(host->card) && \ (host->caps & MMC_CAP_NONREMOVABLE)) && \ (mrq->cmd->error == -ENOTRECOVERABLE || \ ((mrq->cmd->opcode == 17 || mrq->cmd->opcode == 18) && \ ((mrq->data->error) || mrq->cmd->error || \ (mrq->sbc && mrq->sbc->error))))) { +#endif int rt_err = -1,count = 3; printk(KERN_ERR "%s: it occurs a critical error on eMMC " @@ -2440,6 +2450,7 @@ int mmc_suspend_host(struct mmc_host *host) wake_unlock(&host->detect_wake_lock); mmc_flush_scheduled_work(); if (mmc_try_claim_host(host)) { +#ifndef CONFIG_WIMAX_CMC u32 status; u32 count=300000; /* up to 300ms */ @@ -2453,7 +2464,9 @@ int mmc_suspend_host(struct mmc_host *host) "flushing emmc's cache\n", mmc_hostname(host),ret); } +#endif err = mmc_cache_ctrl(host, 0); +#ifndef CONFIG_WIMAX_CMC /* to make sure that emmc is not working. should check emmc's state */ @@ -2469,6 +2482,7 @@ int mmc_suspend_host(struct mmc_host *host) count--; } while (count && R1_CURRENT_STATE(status) == 7); } +#endif mmc_do_release_host(host); } else { err = -EBUSY; |