Explorar o código

UBI: fix bug in image sequence number handling

This patch fixes a bug in the image seq. number handling in the
scanning level. The assignment of the image_seq was incorrect.

Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
Holger Brunck %!s(int64=16) %!d(string=hai) anos
pai
achega
3dc948da78
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      drivers/mtd/ubi/scan.c

+ 1 - 1
drivers/mtd/ubi/scan.c

@@ -781,7 +781,7 @@ static int process_eb(struct ubi_device *ubi, struct ubi_scan_info *si,
 			return -EINVAL;
 			return -EINVAL;
 		}
 		}
 
 
-		image_seq = be32_to_cpu(ech->ec);
+		image_seq = be32_to_cpu(ech->image_seq);
 		if (!si->image_seq_set) {
 		if (!si->image_seq_set) {
 			ubi->image_seq = image_seq;
 			ubi->image_seq = image_seq;
 			si->image_seq_set = 1;
 			si->image_seq_set = 1;