Patchwork [22/23] UBI: Fastmap: Address one of Artems TODOs

login
register
mail settings
Submitter Richard Weinberger
Date June 1, 2012, 3:16 p.m.
Message ID <1338563804-85990-23-git-send-email-richard@nod.at>
Download mbox | patch
Permalink /patch/162347/
State New
Headers show

Comments

Richard Weinberger - June 1, 2012, 3:16 p.m.
/* TODO: If you support fastmap but it was not found, you need to check
 * here that ai does not contain fastmap volumes. If it was corrupted,
 * you need to delete fastmap volumes or possible leftovers of them.
 * And then you have to create _new_ fastmap */

If we support fastmap and it was not found or corrupted we fall back to
scanning mode. While scanning mode the corrupted/partial fastmap will be
deleted.
There is also no need to create a new fastmap here.
It will be created automatically.

Signed-off-by: Richard Weinberger <richard@nod.at>
---
 drivers/mtd/ubi/attach.c |    4 ----
 1 files changed, 0 insertions(+), 4 deletions(-)

Patch

diff --git a/drivers/mtd/ubi/attach.c b/drivers/mtd/ubi/attach.c
index 44f3770..acf7db3 100644
--- a/drivers/mtd/ubi/attach.c
+++ b/drivers/mtd/ubi/attach.c
@@ -1241,10 +1241,6 @@  int ubi_attach(struct ubi_device *ubi)
 	ubi->mean_ec = ai->mean_ec;
 	ubi_msg("max. sequence number:       %llu", ai->max_sqnum);
 
-	/* TODO: If you support fastmap but it was not found, you need to check
-	 * here that ai does not contain fastmap volumes. If it was corrupted,
-	 * you need to delete fastmap volumes or possible leftovers of them.
-	 * And then you have to create _new_ fastmap */
 	err = ubi_read_volume_table(ubi, ai);
 	if (err)
 		goto out_ai;