Loading drivers/mmc/core/core.c +2 −3 Original line number Diff line number Diff line Loading @@ -1203,6 +1203,7 @@ EXPORT_SYMBOL(mmc_check_bkops); * @card: MMC card to start BKOPS * * Send START_BKOPS to the card. * The function should be called with claimed host. */ void mmc_start_manual_bkops(struct mmc_card *card) { Loading @@ -1216,7 +1217,6 @@ void mmc_start_manual_bkops(struct mmc_card *card) if (mmc_card_doing_bkops(card)) return; mmc_claim_host(card->host); err = __mmc_switch(card, EXT_CSD_CMD_SET_NORMAL, EXT_CSD_BKOPS_START, 1, 0, false, true, false); if (err) { Loading @@ -1227,7 +1227,6 @@ void mmc_start_manual_bkops(struct mmc_card *card) mmc_update_bkops_start(&card->bkops.stats); card->bkops.needs_manual = false; } mmc_release_host(card->host); } EXPORT_SYMBOL(mmc_start_manual_bkops); Loading drivers/mmc/core/mmc.c +6 −2 Original line number Diff line number Diff line Loading @@ -2442,6 +2442,9 @@ static int mmc_runtime_idle(struct mmc_host *host) bool halt_cmdq; BUG_ON(!host->card); mmc_claim_host(host); halt_cmdq = mmc_card_cmdq(host->card) && (host->card->bkops.needs_check || host->card->bkops.needs_manual); Loading @@ -2466,10 +2469,9 @@ static int mmc_runtime_idle(struct mmc_host *host) host->card->bkops.needs_check = false; if (host->card->bkops.needs_check) { mmc_claim_host(host); mmc_check_bkops(host->card); host->card->bkops.needs_check = false; mmc_release_host(host); } if (host->card->bkops.needs_manual) Loading @@ -2481,6 +2483,7 @@ static int mmc_runtime_idle(struct mmc_host *host) pr_err("%s: %s failed to unhalt cmdq (%d)\n", mmc_hostname(host), __func__, err); } out: /* * TODO: consider prolonging suspend when bkops Loading @@ -2489,6 +2492,7 @@ out: * */ pm_schedule_suspend(&host->card->dev, MMC_AUTOSUSPEND_DELAY_MS); no_suspend: mmc_release_host(host); pm_runtime_mark_last_busy(&host->card->dev); /* return negative value in order to avoid autosuspend */ return (err) ? err : NO_AUTOSUSPEND; Loading Loading
drivers/mmc/core/core.c +2 −3 Original line number Diff line number Diff line Loading @@ -1203,6 +1203,7 @@ EXPORT_SYMBOL(mmc_check_bkops); * @card: MMC card to start BKOPS * * Send START_BKOPS to the card. * The function should be called with claimed host. */ void mmc_start_manual_bkops(struct mmc_card *card) { Loading @@ -1216,7 +1217,6 @@ void mmc_start_manual_bkops(struct mmc_card *card) if (mmc_card_doing_bkops(card)) return; mmc_claim_host(card->host); err = __mmc_switch(card, EXT_CSD_CMD_SET_NORMAL, EXT_CSD_BKOPS_START, 1, 0, false, true, false); if (err) { Loading @@ -1227,7 +1227,6 @@ void mmc_start_manual_bkops(struct mmc_card *card) mmc_update_bkops_start(&card->bkops.stats); card->bkops.needs_manual = false; } mmc_release_host(card->host); } EXPORT_SYMBOL(mmc_start_manual_bkops); Loading
drivers/mmc/core/mmc.c +6 −2 Original line number Diff line number Diff line Loading @@ -2442,6 +2442,9 @@ static int mmc_runtime_idle(struct mmc_host *host) bool halt_cmdq; BUG_ON(!host->card); mmc_claim_host(host); halt_cmdq = mmc_card_cmdq(host->card) && (host->card->bkops.needs_check || host->card->bkops.needs_manual); Loading @@ -2466,10 +2469,9 @@ static int mmc_runtime_idle(struct mmc_host *host) host->card->bkops.needs_check = false; if (host->card->bkops.needs_check) { mmc_claim_host(host); mmc_check_bkops(host->card); host->card->bkops.needs_check = false; mmc_release_host(host); } if (host->card->bkops.needs_manual) Loading @@ -2481,6 +2483,7 @@ static int mmc_runtime_idle(struct mmc_host *host) pr_err("%s: %s failed to unhalt cmdq (%d)\n", mmc_hostname(host), __func__, err); } out: /* * TODO: consider prolonging suspend when bkops Loading @@ -2489,6 +2492,7 @@ out: * */ pm_schedule_suspend(&host->card->dev, MMC_AUTOSUSPEND_DELAY_MS); no_suspend: mmc_release_host(host); pm_runtime_mark_last_busy(&host->card->dev); /* return negative value in order to avoid autosuspend */ return (err) ? err : NO_AUTOSUSPEND; Loading