lkml.org 
[lkml]   [2012]   [Sep]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
Subjectlinux-next: manual merge of the md tree with the tree
Hi Neil,

Today's linux-next merge of the md tree got a conflict in fs/bio.c
between commit 4363ac7c13a9 ("block: Implement support for WRITE SAME")
from the block tree and commit 368e564836d3 ("block: makes bio_split
support bio without data") from the md tree.

I fixed it up (I think - see below) and can carry the fix as necessary
(no action is required).

--
Cheers,
Stephen Rothwell sfr@canb.auug.org.au

diff --cc fs/bio.c
index f855e0e,dbb7a6c..0000000
--- a/fs/bio.c
+++ b/fs/bio.c
@@@ -1485,20 -1511,19 +1485,21 @@@ struct bio_pair *bio_split(struct bio *
bp->bio2.bi_size -= first_sectors << 9;
bp->bio1.bi_size = first_sectors << 9;

- bp->bv1 = bi->bi_io_vec[0];
- bp->bv2 = bi->bi_io_vec[0];
- if (bio_is_rw(bi)) {
- bp->bv2.bv_offset += first_sectors << 9;
- bp->bv2.bv_len -= first_sectors << 9;
- bp->bv1.bv_len = first_sectors << 9;
- }
+ if (bi->bi_vcnt != 0) {
+ bp->bv1 = bi->bi_io_vec[0];
+ bp->bv2 = bi->bi_io_vec[0];
- bp->bv2.bv_offset += first_sectors << 9;
- bp->bv2.bv_len -= first_sectors << 9;
- bp->bv1.bv_len = first_sectors << 9;
++ if (bio_is_rw(bi)) {
++ bp->bv2.bv_offset += first_sectors << 9;
++ bp->bv2.bv_len -= first_sectors << 9;
++ bp->bv1.bv_len = first_sectors << 9;
++ }

- bp->bio1.bi_io_vec = &bp->bv1;
- bp->bio2.bi_io_vec = &bp->bv2;
+ 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_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;
[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2012-09-21 05:21    [W:0.074 / U:0.456 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site