Patchwork [U-Boot,v2,3/3] mmc: at91: use max timeout value. It will avoid some situation that timeout happened.

login
register
mail settings
Submitter Wu, Josh
Date Sept. 14, 2012, 8:22 a.m.
Message ID <1347610926-18223-4-git-send-email-josh.wu@atmel.com>
Download mbox | patch
Permalink /patch/183831/
State Accepted
Delegated to: Andy Fleming
Headers show

Comments

Wu, Josh - Sept. 14, 2012, 8:22 a.m.
Signed-off-by: Josh Wu <josh.wu@atmel.com>
---
since v1:
  seperate it as one patch from v1.

 drivers/mmc/gen_atmel_mci.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
Andreas Bießmann - Oct. 17, 2012, 9:39 a.m.
Dear Josh Wu,

On 14.09.2012 10:22, Josh Wu wrote:
> Signed-off-by: Josh Wu <josh.wu@atmel.com>
> ---
> since v1:
>   seperate it as one patch from v1.
> 
>  drivers/mmc/gen_atmel_mci.c |    4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)

applied to u-boot-atmel/master, thanks!

Best regards

Andreas Bießmann

Patch

diff --git a/drivers/mmc/gen_atmel_mci.c b/drivers/mmc/gen_atmel_mci.c
index 9f06304..67b2dbe 100644
--- a/drivers/mmc/gen_atmel_mci.c
+++ b/drivers/mmc/gen_atmel_mci.c
@@ -321,8 +321,8 @@  static int mci_init(struct mmc *mmc)
 	writel(MMCI_BIT(MCIEN), &mci->cr);	/* enable mci */
 	writel(MMCI_BF(SCDSEL, MCI_BUS), &mci->sdcr);	/* select port */
 
-	/* Initial Time-outs */
-	writel(0x5f, &mci->dtor);
+	/* This delay can be optimized, but stick with max value */
+	writel(0x7f, &mci->dtor);
 	/* Disable Interrupts */
 	writel(~0UL, &mci->idr);