majianpeng 6c0544e255 md/raid5: Do not add data_offset before call to is_badblock
In chunk_aligned_read() we are adding data_offset before calling
is_badblock.  But is_badblock also adds data_offset, so that is bad.

So move the addition of data_offset to after the call to
is_badblock.

This bug was introduced by commit 31c176ecdf3563140e639
     md/raid5: avoid reading from known bad blocks.
which first appeared in 3.0.  So that patch is suitable for any
-stable kernel from 3.0.y onwards.  However it will need minor
revision for most of those (as the comment didn't appear until
recently).

Cc: stable@vger.kernel.org
Signed-off-by: majianpeng <majianpeng@gmail.com>
Signed-off-by: NeilBrown <neilb@suse.de>
2012-07-03 12:09:57 +10:00
..
2012-03-28 18:41:29 +01:00
2012-03-28 18:41:29 +01:00
2012-03-07 19:09:37 +00:00
2011-03-31 11:26:23 -03:00
2007-10-20 02:01:26 +01:00
2012-03-28 18:43:38 +01:00
2010-08-12 04:14:12 +01:00
2012-03-28 18:41:25 +01:00
2011-10-31 20:19:04 +00:00
2012-03-19 12:46:39 +11:00
2012-03-28 18:43:38 +01:00
2012-03-28 18:43:38 +01:00
2012-05-22 13:55:32 +10:00
2012-03-19 12:46:39 +11:00
2012-05-22 13:55:05 +10:00
2012-05-22 13:53:47 +10:00