The Ux500 has these state transition edges: IDLE -> WAITING_FOR_IRQS -> START_IRQ -> DONE The first IRQ move us from WAITING_FOR_IRQS to START_IRQ and the second IRQ moves us from START_IRQ to DONE. This didn't come out until after all refactoring. For STM32 we keep the END_IRQ state around, because that is indeed what we are waiting for in that case. Signed-off-by: Linus Walleij <linus.walleij@xxxxxxxxxx> --- ChangeLog v1->v2: - No changes --- drivers/mmc/host/mmci.c | 16 +--------------- 1 file changed, 1 insertion(+), 15 deletions(-) diff --git a/drivers/mmc/host/mmci.c b/drivers/mmc/host/mmci.c index 180a7b719347..17233702e7fb 100644 --- a/drivers/mmc/host/mmci.c +++ b/drivers/mmc/host/mmci.c @@ -758,7 +758,7 @@ static bool ux500_busy_complete(struct mmci_host *host, u32 status, u32 err_msk) if (status & host->variant->busy_detect_flag) { host->busy_status |= status & (MCI_CMDSENT | MCI_CMDRESPEND); writel(host->variant->busy_detect_mask, base + MMCICLEAR); - host->busy_state = MMCI_BUSY_END_IRQ; + ux500_busy_clear_mask_done(host); } else { dev_dbg(mmc_dev(host->mmc), "lost busy status when waiting for busy end IRQ\n"); @@ -766,20 +766,6 @@ static bool ux500_busy_complete(struct mmci_host *host, u32 status, u32 err_msk) } break; - /* - * If there is a command in-progress that has been successfully - * sent and the busy bit isn't set, it means we have received - * the busy end IRQ. Clear and mask the IRQ, then continue to - * process the command. - */ - case MMCI_BUSY_END_IRQ: - if (status & host->variant->busy_detect_flag) { - /* We should just get two IRQs for busy detect */ - dev_err(mmc_dev(host->mmc), "spurious busy detect IRQ\n"); - } - ux500_busy_clear_mask_done(host); - break; - case MMCI_BUSY_DONE: break; -- 2.39.2