Commit f0524af0 authored by Neil Brown's avatar Neil Brown Committed by Adrian Bunk

[PATCH] md: Make sure bi_max_vecs is set properly in bio_split

Else a subsequent bio_clone might make a mess.
Signed-off-by: default avatarNeil Brown <neilb@suse.de>
Acked-by: default avatarJens Axboe <axboe@suse.de>
Signed-off-by: default avatarAdrian Bunk <bunk@stusta.de>
parent 6f5bccdd
......@@ -1115,6 +1115,9 @@ struct bio_pair *bio_split(struct bio *bi, mempool_t *pool, int first_sectors)
bp->bio1.bi_io_vec = &bp->bv1;
bp->bio2.bi_io_vec = &bp->bv2;
bp->bio1.bi_max_vecs = 1;
bp->bio2.bi_max_vecs = 1;
bp->bio1.bi_end_io = bio_pair_end_1;
bp->bio2.bi_end_io = bio_pair_end_2;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment