diff options
author | Tom Rini | 2015-08-02 07:40:37 -0400 |
---|---|---|
committer | Tom Rini | 2015-08-02 07:40:37 -0400 |
commit | 7a1af7a79bd79ded6a78d0c1afdbc3353669e313 (patch) | |
tree | 6adcb6dfb2782e8502ca07e2533bee3f95eaeae9 /drivers/mmc | |
parent | 8968b914be7bfd67d179d0395898bd9db67aaad1 (diff) | |
parent | f85764cc1f6ab01ffc60dd78de9c4de4cff2b5ce (diff) |
Merge branch 'master' of git://www.denx.de/git/u-boot-imx
Diffstat (limited to 'drivers/mmc')
-rw-r--r-- | drivers/mmc/fsl_esdhc.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/mmc/fsl_esdhc.c b/drivers/mmc/fsl_esdhc.c index c4719e6f363..0510bf02f41 100644 --- a/drivers/mmc/fsl_esdhc.c +++ b/drivers/mmc/fsl_esdhc.c @@ -341,6 +341,9 @@ esdhc_send_cmd(struct mmc *mmc, struct mmc_cmd *cmd, struct mmc_data *data) err = esdhc_setup_data(mmc, data); if(err) return err; + + if (data->flags & MMC_DATA_READ) + check_and_invalidate_dcache_range(cmd, data); } /* Figure out the transfer arguments */ @@ -437,6 +440,11 @@ esdhc_send_cmd(struct mmc *mmc, struct mmc_cmd *cmd, struct mmc_data *data) } } while ((irqstat & DATA_COMPLETE) != DATA_COMPLETE); + /* + * Need invalidate the dcache here again to avoid any + * cache-fill during the DMA operations such as the + * speculative pre-fetching etc. + */ if (data->flags & MMC_DATA_READ) check_and_invalidate_dcache_range(cmd, data); #endif |