From: Philip Rakity Date: Mon, 14 Feb 2011 07:12:28 +0000 (-0800) Subject: mmc: core: comment on why sdio_reset is done at init time X-Git-Tag: upstream/snapshot3+hdmi~11159^2~14 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=2f94e55ae5ddad83e661002985d2ea11b6d51d3d;p=platform%2Fadaptation%2Frenesas_rcar%2Frenesas_kernel.git mmc: core: comment on why sdio_reset is done at init time sdio_reset sends a CMD52 to reset the sdio card. This is highly recommended for sdio cards being reinitialized. Since we do not know if the card is being reinitialized we just send the command. SD/eMMC cards are supposed to ignore the CMD before the CMD0. Document why we are doing this. Signed-off-by: Philip Rakity Signed-off-by: Chris Ball --- diff --git a/drivers/mmc/core/core.c b/drivers/mmc/core/core.c index 2af2ee1..c47e13b 100644 --- a/drivers/mmc/core/core.c +++ b/drivers/mmc/core/core.c @@ -1494,6 +1494,12 @@ static int mmc_rescan_try_freq(struct mmc_host *host, unsigned freq) mmc_hostname(host), __func__, host->f_init); #endif mmc_power_up(host); + + /* + * sdio_reset sends CMD52 to reset card. Since we do not know + * if the card is being re-initialized, just send it. CMD52 + * should be ignored by SD/eMMC cards. + */ sdio_reset(host); mmc_go_idle(host);