summaryrefslogtreecommitdiff
path: root/drivers/mmc/mmc_write.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/mmc/mmc_write.c')
-rw-r--r--drivers/mmc/mmc_write.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/mmc/mmc_write.c b/drivers/mmc/mmc_write.c
index d23b7d9729..eab94c7b60 100644
--- a/drivers/mmc/mmc_write.c
+++ b/drivers/mmc/mmc_write.c
@@ -102,7 +102,7 @@ ulong mmc_berase(struct blk_desc *block_dev, lbaint_t start, lbaint_t blkcnt)
"The erase range would be change to "
"0x" LBAF "~0x" LBAF "\n\n",
mmc->erase_grp_size, start & ~(mmc->erase_grp_size - 1),
- ((start + blkcnt + mmc->erase_grp_size)
+ ((start + blkcnt + mmc->erase_grp_size - 1)
& ~(mmc->erase_grp_size - 1)) - 1);
while (blk < blkcnt) {