From b8c4dede9e846b6dff35848d9e3de637f2828359 Mon Sep 17 00:00:00 2001 From: lintao Date: Thu, 5 Jun 2014 16:02:21 +0800 Subject: [PATCH] mmc: host:rk_sdmmc: move out effect to sd/sdio --- drivers/mmc/host/rk_sdmmc.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/drivers/mmc/host/rk_sdmmc.c b/drivers/mmc/host/rk_sdmmc.c index a1fd5d377521..cdd86a6ec49c 100755 --- a/drivers/mmc/host/rk_sdmmc.c +++ b/drivers/mmc/host/rk_sdmmc.c @@ -908,7 +908,10 @@ static void dw_mci_setup_bus(struct dw_mci_slot *slot, bool force_clkinit) /* inform CIU */ mci_send_cmd(slot, SDMMC_CMD_UPD_CLK | SDMMC_CMD_PRV_DAT_WAIT, 0); - + + if (!(host->mmc->restrict_caps & RESTRICT_CARD_TYPE_EMMC)) + goto normal; + if(clock == 400*1000){ MMC_DBG_BOOT_FUNC(host->mmc, "dw_mci_setup_bus: argue clk_mmc workaround out 800K for init[%s]", @@ -963,7 +966,7 @@ static void dw_mci_setup_bus(struct dw_mci_slot *slot, bool force_clkinit) } - +normal: /* set clock to desired speed */ mci_writel(host, CLKDIV, div); @@ -1559,6 +1562,9 @@ static int dw_mci_execute_tuning(struct mmc_host *mmc, u32 opcode) struct dw_mci_tuning_data tuning_data; int err = -ENOSYS; + if (!(mmc->restrict_caps & RESTRICT_CARD_TYPE_EMMC)) + return 0; + if (opcode == MMC_SEND_TUNING_BLOCK_HS200) { if (mmc->ios.bus_width == MMC_BUS_WIDTH_8) { tuning_data.blk_pattern = tuning_blk_pattern_8bit; -- 2.34.1