linux-next: manual merge of the md tree with the block tree
From: Stephen Rothwell
Date: Tue Nov 22 2016 - 21:25:41 EST
Hi Shaohua,
Today's linux-next merge of the md tree got a conflict in:
drivers/md/md.c
between commit:
70fd76140a6c ("block,fs: use REQ_* flags directly")
from the block tree and commit:
46533ff7fefb ("md: Use REQ_FAILFAST_* on metadata writes where appropriate")
from the md tree.
I fixed it up (I think - see below) and can carry the fix as necessary.
This is now fixed as far as linux-next is concerned, but any non trivial
conflicts should be mentioned to your upstream maintainer when your tree
is submitted for merging. You may also want to consider cooperating
with the maintainer of the conflicting tree to minimise any particularly
complex conflicts.
--
Cheers,
Stephen Rothwell
diff --cc drivers/md/md.c
index f975cd08923d,c7894fbbd8e5..000000000000
--- a/drivers/md/md.c
+++ b/drivers/md/md.c
@@@ -743,7 -765,12 +765,12 @@@ void md_super_write(struct mddev *mddev
bio_add_page(bio, page, size, 0);
bio->bi_private = rdev;
bio->bi_end_io = super_written;
- bio->bi_opf = REQ_OP_WRITE | REQ_PREFLUSH | REQ_FUA;
+
+ if (test_bit(MD_FAILFAST_SUPPORTED, &mddev->flags) &&
+ test_bit(FailFast, &rdev->flags) &&
+ !test_bit(LastDev, &rdev->flags))
+ ff = MD_FAILFAST;
- bio_set_op_attrs(bio, REQ_OP_WRITE, WRITE_FLUSH_FUA | ff);
++ bio->bi_opf = REQ_OP_WRITE | REQ_PREFLUSH | REQ_FUA | ff;
atomic_inc(&mddev->pending_writes);
submit_bio(bio);