]> git.sur5r.net Git - u-boot/commitdiff
UBI: initialise update marker
authorPeter Horton <zero@colonel-panic.org>
Sat, 12 Jun 2010 01:11:56 +0000 (10:11 +0900)
committerWolfgang Denk <wd@denx.de>
Tue, 22 Jun 2010 22:00:05 +0000 (00:00 +0200)
UBI: initialise update marker

The in kernel copy of a volume's update marker is not initialised from the
volume table. This means that volumes where an update was unfinnished will
not be treated as "forbidden to use". This is basically that the update
functionality was broken.

Signed-off-by: Peter Horton <zero@colonel-panic.org>
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Acked-by: Stefan Roese <sr@denx.de>
drivers/mtd/ubi/vtbl.c

index 9264ac68e8901837d4ab9f5d84f76ec93b48b747..f679f06494b6c79f355976826695693aead1efd0 100644 (file)
@@ -520,6 +520,7 @@ static int init_volumes(struct ubi_device *ubi, const struct ubi_scan_info *si,
                vol->reserved_pebs = be32_to_cpu(vtbl[i].reserved_pebs);
                vol->alignment = be32_to_cpu(vtbl[i].alignment);
                vol->data_pad = be32_to_cpu(vtbl[i].data_pad);
+               vol->upd_marker = vtbl[i].upd_marker;
                vol->vol_type = vtbl[i].vol_type == UBI_VID_DYNAMIC ?
                                        UBI_DYNAMIC_VOLUME : UBI_STATIC_VOLUME;
                vol->name_len = be16_to_cpu(vtbl[i].name_len);