Re: [PATCH] mmc_spi: do propper retry managment in the block layer

From: Pierre Ossman
Date: Fri Apr 10 2009 - 18:10:52 EST


On Wed, 8 Apr 2009 10:55:53 +0100
Wolfgang MÃes <wolfgang.mues@xxxxxxxxxxxx> wrote:

> From: Wolfgang Muees <wolfgang.mues@xxxxxxxxxxxx>
>
> o This patch adds a propper retry managment for reading
> and writing data blocks for mmc and mmc_spi. Blocks are
> retransmitted 2 times in case of a transmission failure.
> This patch was tested with induced transmission errors
> by ESD pulses (and survived).
>
> Signed-off-by: Wolfgang Muees <wolfgang.mues@xxxxxxxxxxxx>
>

NAK. Writes cannot be retried safely as upper layers rely on the fact
that writes fail in a linear manner (a stupid assumption IMO, but
that's the way things are).

> + /* Invalid response. This is most likely a transmission
> + * error from card to host.
> + */
> + case -EINVAL:

EINVAL is actually "host controller driver/hardware does not support
this type of request".

Rgds
--
-- 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
encryption.

Attachment: signature.asc
Description: PGP signature