]> git.baikalelectronics.ru Git - kernel.git/commit
mmc: dw_mmc: handle "no CRC status" error
authorJames Hogan <james.hogan@imgtec.com>
Wed, 29 Jun 2011 08:29:58 +0000 (09:29 +0100)
committerChris Ball <cjb@laptop.org>
Wed, 20 Jul 2011 21:21:06 +0000 (17:21 -0400)
commit1b1be03600a38bcc46fd02a42fc23248c1725203
treead31ddb71b4482c57b5affc9543a4d64c751ac6c
parent457e7847e262a07bc8d498228ab03b88eceeb1c9
mmc: dw_mmc: handle "no CRC status" error

When a data write isn't acknowledged by the card (so no CRC status token
is detected after the data), the error -EIO is returned instead of the
-ETIMEDOUT expected by mmc_test 15 - "Correct xfer_size at write (start
failure)" and 17 "Correct xfer_size at write (midway failure)". In PIO
mode the reported number of bytes transferred is also exaggerated since
the last block actually failed.

Handle the "Write no CRC" error specially, setting the error to
-ETIMEDOUT and setting the bytes_xferred to 0.

Signed-off-by: James Hogan <james.hogan@imgtec.com>
Acked-by: Will Newton <will.newton@imgtec.com>
Tested-by: Jaehoon Chung <jh80.chung@samsung.com>
Signed-off-by: Chris Ball <cjb@laptop.org>
drivers/mmc/host/dw_mmc.c