]> git.ipfire.org Git - people/arne_f/kernel.git/commit
UBI: fix out of bounds write
authorBrian Norris <computersforpeace@gmail.com>
Sat, 28 Feb 2015 10:23:26 +0000 (02:23 -0800)
committerJiri Slaby <jslaby@suse.cz>
Mon, 4 May 2015 09:50:08 +0000 (11:50 +0200)
commit8926a8a1855b8edc24780c31b6a734901cb42f43
tree7cd03d33b1fbb7b1c26c795cb190745ba4350c15
parentfa4a3fc61b8cfc9c9ee19215906f496804d30751
UBI: fix out of bounds write

commit d74adbdb9abf0d2506a6c4afa534d894f28b763f upstream.

If aeb->len >= vol->reserved_pebs, we should not be writing aeb into the
PEB->LEB mapping.

Caught by Coverity, CID #711212.

Signed-off-by: Brian Norris <computersforpeace@gmail.com>
Signed-off-by: Richard Weinberger <richard@nod.at>
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
drivers/mtd/ubi/eba.c