public inbox for linux-mmc@vger.kernel.org
 help / color / mirror / Atom feed
From: Wolfram Sang <wsa+renesas@sang-engineering.com>
To: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: Linux MMC List <linux-mmc@vger.kernel.org>,
	Linux-Renesas <linux-renesas-soc@vger.kernel.org>,
	Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
Subject: Re: [PATCH v3 3/3] mmc: renesas_sdhi: do hard reset if possible
Date: Fri, 18 Jun 2021 11:36:48 +0200	[thread overview]
Message-ID: <YMxpMKH39aYs4Zaz@ninjato> (raw)
In-Reply-To: <CAMuHMdU6=rTHjvcgK8GBzd3OL_9YFqV77=KsAEGJvAVapnhsOQ@mail.gmail.com>

[-- Attachment #1: Type: text/plain, Size: 1819 bytes --]

Hi Geert,

> In v5.10, v5.11, and v512, it works fine:
> 
>     sh_mobile_sdhi ee100000.mmc: timeout waiting for hardware interrupt (CMD19)
>     mmc0: new ultra high speed SDR104 SDHC card at address aaaa
>     mmcblk0: mmc0:aaaa SM32G 29.7 GiB
>       mmcblk0: p1
> 
> Note that I do see one timeout during identification.
> 
> After b4d86f37eacb7246 (bisected), it fails:
> 
>     sh_mobile_sdhi ee100000.mmc: timeout waiting for hardware interrupt (CMD19)
>     sh_mobile_sdhi ee100000.mmc: timeout waiting for hardware interrupt (CMD19)
>     [...]
>     sh_mobile_sdhi ee100000.mmc: timeout waiting for hardware interrupt (CMD19)
>     mmc0: tuning execution failed: -5
>     mmc0: error -5 whilst initialising SD card
>     sh_mobile_sdhi ee100000.mmc: timeout waiting for hardware interrupt (CMD19)
>     sh_mobile_sdhi ee100000.mmc: timeout waiting for hardware interrupt (CMD19)
>     [...]
> 
> Given the single timeout I see with older kernels, the issue may be that the
> harder reset causes that timeout to repeat ad infinitum?

I can confirm this. I also found a SanDisk card which shows the same
issue on my Lager board. However, I wouldn't say this patch breaks
things in a way that a revert is a good solution.

The card does not really work "fine". During probe we get one timeout,
and when trying to read from the card, more follow. Already before this
patch. There seems to be a state where an initial command fails and only
the retry suceeds. The hard reset in deed seems to cause an endless loop
here. However, the proper fix is to find out why this first command
fails, especially only with some cards. My Samsung one works 100% fine.

And if we fix this, then the hard reset is still good for Gen2 as well.

Makes sense?

All the best,

   Wolfram


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

  reply	other threads:[~2021-06-18  9:36 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-17  9:16 [PATCH v3 0/3] mmc: renesas_sdhi: reset via reset controller Wolfram Sang
2021-03-17  9:16 ` [PATCH v3 1/3] mmc: tmio: abort DMA before reset Wolfram Sang
2021-03-17  9:16 ` [PATCH v3 2/3] mmc: renesas_sdhi: break SCC reset into own function Wolfram Sang
2021-03-17  9:16 ` [PATCH v3 3/3] mmc: renesas_sdhi: do hard reset if possible Wolfram Sang
2021-04-28 14:36   ` Geert Uytterhoeven
2021-06-18  9:36     ` Wolfram Sang [this message]
2021-06-18  9:42       ` Geert Uytterhoeven
2021-06-18  9:57         ` Wolfram Sang
2021-06-18 10:53           ` Geert Uytterhoeven
2021-08-26  8:16     ` Wolfram Sang
2021-03-19 14:12 ` [PATCH v3 0/3] mmc: renesas_sdhi: reset via reset controller Ulf Hansson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=YMxpMKH39aYs4Zaz@ninjato \
    --to=wsa+renesas@sang-engineering.com \
    --cc=geert@linux-m68k.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=linux-renesas-soc@vger.kernel.org \
    --cc=yoshihiro.shimoda.uh@renesas.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox