From: Boaz Harrosh Date: Wed, 28 Dec 2011 17:14:23 +0000 (+0200) Subject: ore: fix BUG_ON, too few sgs when reading X-Git-Tag: v3.2.1~30 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0889c179651f57c6fdf4ed72e5027c5dcc90bda2;p=pandora-kernel.git ore: fix BUG_ON, too few sgs when reading commit 361aba569f55dd159b850489a3538253afbb3973 upstream. When reading RAID5 files, in rare cases, we calculated too few sg segments. There should be two extra for the beginning and end partial units. Also "too few sg segments" should not be a BUG_ON there is all the mechanics in place to handle it, as a short read. So just return -ENOMEM and the rest of the code will gracefully split the IO. Signed-off-by: Boaz Harrosh Signed-off-by: Greg Kroah-Hartman --- Reading git-diff-tree failed