mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
synced 2025-01-11 00:08:50 +00:00
[PATCH] tidy "md: check bio address after mapping through partitions"
Neil's xterms are too wide. Cc: Neil Brown <neilb@cse.unsw.edu.au> Cc: Jens Axboe <jens.axboe@oracle.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:
parent
7bd473fcc2
commit
df66b8552b
@ -3075,11 +3075,12 @@ end_io:
|
|||||||
if (maxsector) {
|
if (maxsector) {
|
||||||
sector_t sector = bio->bi_sector;
|
sector_t sector = bio->bi_sector;
|
||||||
|
|
||||||
if (maxsector < nr_sectors || maxsector - nr_sectors < sector) {
|
if (maxsector < nr_sectors ||
|
||||||
|
maxsector - nr_sectors < sector) {
|
||||||
/*
|
/*
|
||||||
* This may well happen - partitions are not checked
|
* This may well happen - partitions are not
|
||||||
* to make sure they are within the size of the
|
* checked to make sure they are within the size
|
||||||
* whole device.
|
* of the whole device.
|
||||||
*/
|
*/
|
||||||
handle_bad_sector(bio);
|
handle_bad_sector(bio);
|
||||||
goto end_io;
|
goto end_io;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user