On Thursday 04 September 2014 17:37:59 Dong Aisheng wrote:
> index 49f04bc..83d17a9 100644
> --- a/drivers/mmc/core/mmc_ops.c
> +++ b/drivers/mmc/core/mmc_ops.c
> @@ -440,6 +440,12 @@ int __mmc_switch(struct mmc_card *card, u8 set,
> u8 index, u8 value,
>         if (!use_busy_signal)
>                 return 0;
> 
> +       /*
> +        * WORKAROUND: for Sandisk eMMC cards, it might need certain delay
> +        * before sending CMD13 after CMD6
> +        */
> +       mdelay(1);
> +
>         /* Must check status to be sure of no errors */
>         timeout = jiffies + msecs_to_jiffies(MMC_OPS_TIMEOUT_MS);
>         do {
> 
> 

mdelay() is a rather nasty function to call because it hogs the CPU.
Better use msleep(), which will allow another process to use the
CPU in the meantime.
It might be worthwhile to check the manufacturer ID field so we
don't delay the boot process for non-sandisk devices.

        Arnd
--
To unsubscribe from this list: send the line "unsubscribe linux-mmc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to