Skip to content

Commit

Permalink
omap: mmc: Adjust dto to eliminate timeout errors
Browse files Browse the repository at this point in the history
A number of SD card types were experiencing timeout errors.  This
could also lead to data corruption in some cases.

This fix proposed by Sukumar Ghoral of TI.
  • Loading branch information
sakoman committed Jan 12, 2011
1 parent aef7efb commit 67343cb
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions drivers/mmc/host/omap_hsmmc.c
Expand Up @@ -1353,6 +1353,7 @@ static void set_data_timeout(struct omap_hsmmc_host *host,
cycle_ns = 1000000000 / (clk_get_rate(host->fclk) / clkd);
timeout = timeout_ns / cycle_ns;
timeout += timeout_clks;
timeout *= 2;
if (timeout) {
while ((timeout & 0x80000000) == 0) {
dto += 1;
Expand Down

0 comments on commit 67343cb

Please sign in to comment.