From e1b213ceabcc5984c7cb9e73c44eaced31c6d7e9 Mon Sep 17 00:00:00 2001 From: Artem Bityutskiy Date: Sun, 26 Jul 2009 18:06:58 +0300 Subject: ubinize: add sequence number support UBI now supports the image sequence number feature which prevents UBI from mistakingly accepting half-written images, if the image was written on top of an older image. Support this feature in ubinize and make it pick a random number for the UBI image sequence number. Signed-off-by: Artem Bityutskiy --- ubi-utils/src/ubiformat.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'ubi-utils/src/ubiformat.c') diff --git a/ubi-utils/src/ubiformat.c b/ubi-utils/src/ubiformat.c index 55ce7aa..a2ca572 100644 --- a/ubi-utils/src/ubiformat.c +++ b/ubi-utils/src/ubiformat.c @@ -875,7 +875,7 @@ int main(int argc, char * const argv[]) normsg("use erase counter %lld for all eraseblocks", args.ec); ubigen_info_init(&ui, mtd.eb_size, mtd.min_io_size, mtd.subpage_size, - args.vid_hdr_offs, args.ubi_ver); + args.vid_hdr_offs, args.ubi_ver, 0); if (si->vid_hdr_offs != -1 && ui.vid_hdr_offs != si->vid_hdr_offs) { /* @@ -895,7 +895,7 @@ int main(int argc, char * const argv[]) printf("yes\n"); } else ubigen_info_init(&ui, mtd.eb_size, mtd.min_io_size, 0, - si->vid_hdr_offs, args.ubi_ver); + si->vid_hdr_offs, args.ubi_ver, 0); normsg("use offsets %d and %d", ui.vid_hdr_offs, ui.data_offs); } -- cgit v1.2.3