Hi Fabio,

On 12/02/2015 10:23 AM, Fabio Estevam wrote:
> Hi Eric,
> 
> On Tue, Dec 1, 2015 at 5:05 PM, Eric Nelson <e...@nelint.com> wrote:
> 
>> I've also recently seen this on two different custom boards. Both are
>> running i.MX6Q TO1.2 and both are using eMMC from Micron.
> 
> One colleague of mine tested eMMC erasure on a mx6qsabresd revC5 board
> with a eMMC from Micron and it worked fine.
> 
> So far I see:
> 
> revB and revC5: works
> revC2 and revC4: don't work
> 

We're seeing this pretty intermittently and only with certain
devices from the same batch, so I'm not sure I'd conclude that the
problem won't happen on revB or revC5.

>>
>> The code which is generating the error message:
>>
>>         
>> http://git.denx.de/?p=u-boot.git;a=blob;f=drivers/mmc/fsl_esdhc.c;h=c5054d66bdcda029f0485958c87bd5154ccee591;hb=HEAD#l390
>>
>> Seems to refer to an errata for the i.MX35 (ENGcm03648):
>>         http://cache.freescale.com/files/dsp/doc/errata/IMX35CE.pdf
>>
>> I don't see any reference to the errata in the i.MX6 docs.
> 
> This piece of code came from:
> 7a5b80297bc6cef ("mmc: fsl_esdhc: Poll until card is not busy anymore")
> 
> Yes, ENGcm03648 is not listed in mx6 errata document.
> 
>> Ignoring the error (removing the return statement) seems to leave things
>> in a workable state, so I suspect the problem isn't with an insufficient
>> timeout.
> 
> May I see your change, please?
> 

Sure. It's a hack, but shows where we're hitting the problem
(with the stop command).

We haven't been using the "mmc erase" command, but see this when
using ums to program eMMC.

Regards,


Eric
>From e647278657e32f74833eadc5f2cbe4d121c22842 Mon Sep 17 00:00:00 2001
From: Eric Nelson <e...@nelint.com>
Date: Tue, 17 Nov 2015 15:35:32 -0700
Subject: [PATCH] mmc: try to continue after failure in stop command

---
 drivers/mmc/mmc.c       | 3 +--
 drivers/mmc/mmc_write.c | 3 +--
 2 files changed, 2 insertions(+), 4 deletions(-)

diff --git a/drivers/mmc/mmc.c b/drivers/mmc/mmc.c
index 2a58702..53084a7 100644
--- a/drivers/mmc/mmc.c
+++ b/drivers/mmc/mmc.c
@@ -225,9 +225,8 @@ static int mmc_read_blocks(struct mmc *mmc, void *dst, lbaint_t start,
 		cmd.resp_type = MMC_RSP_R1b;
 		if (mmc_send_cmd(mmc, &cmd, NULL)) {
 #if !defined(CONFIG_SPL_BUILD) || defined(CONFIG_SPL_LIBCOMMON_SUPPORT)
-			printf("mmc fail to send stop cmd\n");
+			printf("%s: mmc fail to send stop cmd\n", __func__);
 #endif
-			return 0;
 		}
 	}
 
diff --git a/drivers/mmc/mmc_write.c b/drivers/mmc/mmc_write.c
index 7aea7e9..a417d25 100644
--- a/drivers/mmc/mmc_write.c
+++ b/drivers/mmc/mmc_write.c
@@ -153,8 +153,7 @@ static ulong mmc_write_blocks(struct mmc *mmc, lbaint_t start,
 		cmd.cmdarg = 0;
 		cmd.resp_type = MMC_RSP_R1b;
 		if (mmc_send_cmd(mmc, &cmd, NULL)) {
-			printf("mmc fail to send stop cmd\n");
-			return 0;
+			printf("%s: mmc fail to send stop cmd\n", __func__);
 		}
 	}
 
--
libgit2 0.21.2

_______________________________________________
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

Reply via email to