Re: [PATCH] mvsdio: fix config failure with some high speed SDHCcards
From: Pierre Ossman
Date: Wed May 27 2009 - 16:26:44 EST
On Tue, 26 May 2009 22:35:34 -0400 (EDT)
Nicolas Pitre <nico@xxxxxxx> wrote:
> Especially with Sandisk SDHC cards, the second SWITCH command was failing
> with a timeout and the card was not recognized at all. However if the
> system was busy, or debugging was enabled, or a udelay(100) was inserted
> before the second SWITCH command in the core code, then the timing was
> so that the card started to work.
> This appears to be a problem with the host hardware. With some unusual
> block sizes, the data FIFO status doesn't indicate a "empty" state right
> away when the data transfer is done. Queuing another data transfer in
> that condition results in a transfer timeout.
> The empty FIFO bit eventually get set by itself in less than 50 usecs
> when it is not set right away. So let's just poll for that bit before
> configuring the controller with a new data transfer.
> Signed-off-by: Nicolas Pitre <nico@xxxxxxxxxxx>
You seem to be having a lot of fun with this controller. :)
-- Pierre Ossman
WARNING: This correspondence is being monitored by the
Swedish government. Make sure your server uses encryption
for SMTP traffic and consider using PGP for end-to-end
Description: PGP signature