Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 6248abb7 authored by Richard Weinberger's avatar Richard Weinberger Committed by Tatyana Brokhman
Browse files

UBI: Fix error path in scan_pool()



We have to set "ret", not "err" in case of an error.

Change-Id: Ieb9ad2105a0047df4696fa8edf8bb25541600643
Reported-and-tested-by: default avatarRichard Genoud <richard.genoud@gmail.com>
Signed-off-by: default avatarRichard Weinberger <richard@nod.at>
Signed-off-by: default avatarArtem Bityutskiy <artem.bityutskiy@linux.intel.com>
Git-commit: f240dca8f2fdf11d52a7bacd867e274c3b21a7d3
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git


Signed-off-by: default avatarTatyana Brokhman <tlinder@codeaurora.org>
parent a2e100e6
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -428,7 +428,7 @@ static int scan_pool(struct ubi_device *ubi, struct ubi_attach_info *ai,
		if (be32_to_cpu(ech->image_seq) != ubi->image_seq) {
			ubi_err("bad image seq: 0x%x, expected: 0x%x",
				be32_to_cpu(ech->image_seq), ubi->image_seq);
			err = UBI_BAD_FASTMAP;
			ret = UBI_BAD_FASTMAP;
			goto out;
		}