From: Richard Weinberger Date: Mon, 10 Nov 2014 15:16:23 +0000 (+0100) Subject: UBI: Fix stale pointers in ubi->lookuptbl X-Git-Tag: omap-for-v4.1/fixes-rc1~135^2~14 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ee59ba8b064f692a1dee99b6f3ba30b0e904b2c1;p=pandora-kernel.git UBI: Fix stale pointers in ubi->lookuptbl In some error paths the WL sub-system gives up on a PEB and frees it's ubi_wl_entry struct but does not set the entry in ubi->lookuptbl to NULL. Fastmap can stumble over such a stale pointer as it uses ubi->lookuptbl to find all PEBs. Fix this by introducing a new helper function which free()s a WL entry and removes the reference from the lookup table. Signed-off-by: Richard Weinberger --- Reading git-diff-tree failed