aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/mtd/mtdconcat.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/mtd/mtdconcat.c')
-rw-r--r--drivers/mtd/mtdconcat.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/mtd/mtdconcat.c b/drivers/mtd/mtdconcat.c
index b1bf8c411de7..9af840364a74 100644
--- a/drivers/mtd/mtdconcat.c
+++ b/drivers/mtd/mtdconcat.c
@@ -477,8 +477,7 @@ static int concat_erase(struct mtd_info *mtd, struct erase_info *instr)
477 } 477 }
478 478
479 /* must never happen since size limit has been verified above */ 479 /* must never happen since size limit has been verified above */
480 if (i >= concat->num_subdev) 480 BUG_ON(i >= concat->num_subdev);
481 BUG();
482 481
483 /* now do the erase: */ 482 /* now do the erase: */
484 err = 0; 483 err = 0;
@@ -500,8 +499,7 @@ static int concat_erase(struct mtd_info *mtd, struct erase_info *instr)
500 if ((err = concat_dev_erase(subdev, erase))) { 499 if ((err = concat_dev_erase(subdev, erase))) {
501 /* sanity check: should never happen since 500 /* sanity check: should never happen since
502 * block alignment has been checked above */ 501 * block alignment has been checked above */
503 if (err == -EINVAL) 502 BUG_ON(err == -EINVAL);
504 BUG();
505 if (erase->fail_addr != 0xffffffff) 503 if (erase->fail_addr != 0xffffffff)
506 instr->fail_addr = erase->fail_addr + offset; 504 instr->fail_addr = erase->fail_addr + offset;
507 break; 505 break;