]> git.baikalelectronics.ru Git - kernel.git/commit
ore: fix BUG_ON, too few sgs when reading
authorBoaz Harrosh <bharrosh@panasas.com>
Wed, 28 Dec 2011 17:14:23 +0000 (19:14 +0200)
committerBoaz Harrosh <bharrosh@panasas.com>
Fri, 6 Jan 2012 14:49:07 +0000 (16:49 +0200)
commit15c618e4b32322c105d979edaa5592122eb15edc
treee5a71f53908a67d8873f1a58ae8d83c64b2fdd7f
parent15ba6d89b2196bdf052299a6ecd67e1c0e8e37a8
ore: fix BUG_ON, too few sgs when reading

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.

[Bug in 3.2.0 Kernel]
CC: Stable Tree <stable@kernel.org>
Signed-off-by: Boaz Harrosh <bharrosh@panasas.com>
fs/exofs/ore.c
fs/exofs/ore_raid.c