diff options
author | Przemyslaw Marczak <p.marczak@samsung.com> | 2013-10-08 18:12:09 +0200 |
---|---|---|
committer | Pantelis Antoniou <panto@antoniou-consulting.com> | 2013-10-31 09:55:33 +0200 |
commit | 56b34bc617f64ce34b34cebc7cbde7a8e4c1002f (patch) | |
tree | d9716cee9cc8083c8a6194284c0518f81d5dcf0e /include/zfs_common.h | |
parent | b44fe83a580c21082486931367277c02d48c6469 (diff) | |
download | u-boot-imx-56b34bc617f64ce34b34cebc7cbde7a8e4c1002f.zip u-boot-imx-56b34bc617f64ce34b34cebc7cbde7a8e4c1002f.tar.gz u-boot-imx-56b34bc617f64ce34b34cebc7cbde7a8e4c1002f.tar.bz2 |
mmc: sdhci: Avoid commands errors by simple timeout adaptation.
Old command timeout value was too small and it caused I/O errors which
led to uncompleted read/write/erase operations and filesystem errors.
Timeout adaptation fixes this issue.
Changes in sdhci_send_command() function:
- change timeout variable to static
- increase default command timeout to 100 ms
- add definition of max command timeout value,
which can be redefined in each board config file
- wait for card ready state for max defined time
if it doesn't exceed defined maximum or return COMM_ERR
Once successfully increased timeout value will be used in next function
call. This fix was tested on Goni, Trats, Trats2 boards by testing UMS
on MMC storage.
Changes v2:
- move global variable cmd_timeout into function sdhci_send_command()
- change condition "==" to ">=" when comparing time with timeout
- print information about timeout increasing and card busy timeout
Signed-off-by: Przemyslaw Marczak <p.marczak@samsung.com>
Cc: Pantelis Antoniou <panto@antoniou-consulting.com>
Diffstat (limited to 'include/zfs_common.h')
0 files changed, 0 insertions, 0 deletions