RE: [PATCH] mmc: core: add an error log for cid verification

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> On Thu, 21 Feb 2019 at 08:16, hongjiefang <hongjiefang@xxxxxxxxxxxx> wrote:
> >
> > when failed to verify the cid, the card initialisation will abort.
> > it is necessary to print some logs for this critical error.
> 
> Under what circumstances do you observe this error? Is it during
> system resume or during runtime resume?
> 
> Moreover, to get this error, I guess you are remove one card and
> replacing it with another, right?

It happened when the system resume a non-removable eMMC card
from deep suspend.

> Just wanted to be sure of what kind of scenario you are
> testing/looking at. Perhaps you could even fold in some of that
> information in the changelog, that would be nice.

During the eMMC resume stage, CMD2 returned an error CID value
but without any error INT status.
The error CID values are as follow 15010044, 4436384d, 4202c2c0, ff808000.
The correct value should be 15010044, 4436384d, 4202c2d8, dc2f9400.
"c0ff8080" is the response from CMD1.

This problem occasionally occurred when system resume from suspend status.
Maybe it happened because there is something wrong about bus clock or our host
when system do resume. It needs further debugging.

> 
> >
> > Signed-off-by: hongjiefang <hongjiefang@xxxxxxxxxxxx>
> > ---
> >  drivers/mmc/core/mmc.c | 2 ++
> >  1 file changed, 2 insertions(+)
> >
> > diff --git a/drivers/mmc/core/mmc.c b/drivers/mmc/core/mmc.c
> > index da892a5..339015c 100644
> > --- a/drivers/mmc/core/mmc.c
> > +++ b/drivers/mmc/core/mmc.c
> > @@ -1595,6 +1595,8 @@ static int mmc_init_card(struct mmc_host *host, u32 ocr,
> >         if (oldcard) {
> >                 if (memcmp(cid, oldcard->raw_cid, sizeof(cid)) != 0) {
> >                         err = -ENOENT;
> > +                       pr_err("%s: Failed to verify the cid, error %d\n",
> > +                               mmc_hostname(host), err);
> >                         goto err;
> >                 }
> >
> > --
> > 1.9.1
> >
> 
> Kind regards
> Uffe


B&R
Hongjie




[Index of Archives]     [Linux Memonry Technology]     [Linux USB Devel]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux