]> git.karo-electronics.de Git - karo-tx-linux.git/commit
fs/partitions/ldm.c: fix oops caused by corrupted partition table
authorTimo Warns <Warns@pre-sense.de>
Thu, 14 Apr 2011 22:21:56 +0000 (15:21 -0700)
committerGreg Kroah-Hartman <gregkh@suse.de>
Mon, 9 May 2011 22:06:49 +0000 (15:06 -0700)
commitc99afaf0385d61a8e1747511904c66838270b02b
tree4960232669661ffea3ca2357082a2c540f061bef
parentba1ba1c0aaa659914bf9d47616453f6378add40f
fs/partitions/ldm.c: fix oops caused by corrupted partition table

commit c340b1d640001c8c9ecff74f68fd90422ae2448a upstream.

The kernel automatically evaluates partition tables of storage devices.
The code for evaluating LDM partitions (in fs/partitions/ldm.c) contains
a bug that causes a kernel oops on certain corrupted LDM partitions.
A kernel subsystem seems to crash, because, after the oops, the kernel no
longer recognizes newly connected storage devices.

The patch validates the value of vblk_size.

[akpm@linux-foundation.org: coding-style fixes]
Signed-off-by: Timo Warns <warns@pre-sense.de>
Cc: Eugene Teo <eugeneteo@kernel.sg>
Cc: Harvey Harrison <harvey.harrison@gmail.com>
Cc: Richard Russon <rich@flatcap.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
fs/partitions/ldm.c