Patchwork [16/23] UBI: Fastmap: Store bad_peb_count in fastmap

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

Comments

Richard Weinberger - June 1, 2012, 3:16 p.m.
Signed-off-by: Richard Weinberger <richard@nod.at>
---
 drivers/mtd/ubi/fastmap.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

Patch

diff --git a/drivers/mtd/ubi/fastmap.c b/drivers/mtd/ubi/fastmap.c
index dad0251..85474a8 100644
--- a/drivers/mtd/ubi/fastmap.c
+++ b/drivers/mtd/ubi/fastmap.c
@@ -1003,6 +1003,7 @@  static int ubi_write_fastmap(struct ubi_device *ubi,
 		feba->magic = UBI_FM_EBA_MAGIC;
 	}
 	fmh->vol_count = cpu_to_be32(vol_count);
+	fmh->bad_peb_count = cpu_to_be32(ubi->bad_peb_count);
 
 	avhdr->sqnum = cpu_to_be64(ubi_next_sqnum(ubi));
 	avhdr->lnum = 0;