From: Siva Durga Prasad Paladugu Date: Tue, 2 Feb 2016 05:10:16 +0000 (+0530) Subject: mmc: mmc_write: Write only single block at a time X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=69ea56c61f09a058cd413f87b2a0a41ca4d6f474;p=thirdparty%2Fu-boot.git mmc: mmc_write: Write only single block at a time Write only single block at a time while doing write operations mmc/SD/eMMC This is workaround for an issue with multiple block write Signed-off-by: Siva Durga Prasad Paladugu Signed-off-by: Michal Simek --- diff --git a/drivers/mmc/mmc_write.c b/drivers/mmc/mmc_write.c index 221bf306cc5..18cb94f1b03 100644 --- a/drivers/mmc/mmc_write.c +++ b/drivers/mmc/mmc_write.c @@ -179,6 +179,12 @@ ulong mmc_bwrite(int dev_num, lbaint_t start, lbaint_t blkcnt, const void *src) do { cur = (blocks_todo > mmc->cfg->b_max) ? mmc->cfg->b_max : blocks_todo; + /* + * FIXME: Workaround to always use + * single block write instead of + * multiple block. + */ + cur = 1; if (mmc_write_blocks(mmc, start, cur, src) != cur) return 0; blocks_todo -= cur;