From patchwork Tue Dec 13 23:31:23 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Rothwell X-Patchwork-Id: 9486801 X-Mozilla-Keys: nonjunk Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on sandeen.net X-Spam-Level: X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, T_DKIM_INVALID, URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 X-Spam-HP: BAYES_00=-1.9, DKIM_SIGNED=0.1, HEADER_FROM_DIFFERENT_DOMAINS=0.001, RCVD_IN_DNSWL_HI=-5,RP_MATCHES_RCVD=-0.1,T_DKIM_INVALID=0.01, URIBL_BLOCKED=0.001 X-Original-To: sandeen@sandeen.net Delivered-To: sandeen@sandeen.net Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by sandeen.net (Postfix) with ESMTP id 5FDE98D for ; Tue, 13 Dec 2016 17:34:29 -0600 (CST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751455AbcLMXdr (ORCPT ); Tue, 13 Dec 2016 18:33:47 -0500 Received: from ozlabs.org ([103.22.144.67]:54177 "EHLO ozlabs.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750899AbcLMXdq (ORCPT ); Tue, 13 Dec 2016 18:33:46 -0500 Received: from authenticated.ozlabs.org (localhost [127.0.0.1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPSA id 3tdbZ40v1lz9t1C; Wed, 14 Dec 2016 10:31:24 +1100 (AEDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=canb.auug.org.au; s=201601; t=1481671884; bh=gA3Q2OswOXKYIpzALTpDIEBkdPUefyF2bCq5A9tUpiA=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=QRsFyE6xWzamYgRYZb+EjOGurFhAgk0yhbn1PcZfK80OIX/Uds+PTIpC2qDyx5uuI IY/aNSDdF+xiREnEyWyIGZK5vBHF5qHd3BQoBwIQo3DMHgw8kJEZJZ9cMKBH3bm24g JavnQ9kRplyn3g87xI6iJkBbE9Bh/KKUzN6L1Vnc= Date: Wed, 14 Dec 2016 10:31:23 +1100 From: Stephen Rothwell To: Linus Torvalds Cc: Jens Axboe , "linux-kernel@vger.kernel.org" , "linux-block@vger.kernel.org" , David Chinner , linux-xfs@vger.kernel.org, Christoph Hellwig Subject: Re: [GIT PULL] Block core changes for 4.10 Message-ID: <20161214103123.20d9b2d0@canb.auug.org.au> In-Reply-To: <6176de36-7f4f-040b-f277-e872cc98eb5e@kernel.dk> References: <6176de36-7f4f-040b-f277-e872cc98eb5e@kernel.dk> MIME-Version: 1.0 Sender: linux-xfs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-xfs@vger.kernel.org Hi Linus, On Sun, 11 Dec 2016 18:52:29 -0700 Jens Axboe wrote: > > Note that this pull will throw 3 trivial merge conflicts, since we had > patches that went into mainline after 4.9-rc1 (upon which this branch is > based), and one that will not show up in block/blk-flush.c. The latter > is due to a fix that went in for the flush code using an old request > flag that is now changed to a per-request one. To ensure that this all > goes smoothly, I just merged 4.9 with this branch and provide that as a > reference: > > git://git.kernel.dk/linux-block.git for-4.10/merge > > But really, the only one you to watch for is this line in > block/blk-flush.c: > > /* for avoiding double accounting */ > rq->cmd_flags &= ~REQ_STARTED; > > which should now be: > > rq->rq_flags &= ~RQF_STARTED; > > and the three merge conflicts that do show up are trivially resolvable. I have also been carrying a fix patch for the merge between the block tree and the xfs tree: Commits 70fd76140a6c ("block,fs: use REQ_* flags directly") bbd7bb7017d5 ("block: move poll code to blk-mq") from the block tree interacting with commit ff6a9292e6f6 ("iomap: implement direct I/O") from the xfs tree. From: Stephen Rothwell Date: Thu, 1 Dec 2016 13:45:33 +1100 Subject: [PATCH] iomap: fix up for blk_poll and WRITE_ODIRECT change Signed-off-by: Stephen Rothwell --- fs/iomap.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/fs/iomap.c b/fs/iomap.c index fc2446242935..c9d6c1176345 100644 --- a/fs/iomap.c +++ b/fs/iomap.c @@ -722,7 +722,7 @@ iomap_dio_zero(struct iomap_dio *dio, struct iomap *iomap, loff_t pos, get_page(page); if (bio_add_page(bio, page, len, 0) != len) BUG(); - bio_set_op_attrs(bio, REQ_OP_WRITE, WRITE_ODIRECT); + bio_set_op_attrs(bio, REQ_OP_WRITE, REQ_SYNC | REQ_IDLE); atomic_inc(&dio->ref); return submit_bio(bio); @@ -805,7 +805,7 @@ iomap_dio_actor(struct inode *inode, loff_t pos, loff_t length, } if (dio->flags & IOMAP_DIO_WRITE) { - bio_set_op_attrs(bio, REQ_OP_WRITE, WRITE_ODIRECT); + bio_set_op_attrs(bio, REQ_OP_WRITE, REQ_SYNC | REQ_IDLE); task_io_account_write(bio->bi_iter.bi_size); } else { bio_set_op_attrs(bio, REQ_OP_READ, 0); @@ -930,7 +930,7 @@ iomap_dio_rw(struct kiocb *iocb, struct iov_iter *iter, struct iomap_ops *ops, if (!(iocb->ki_flags & IOCB_HIPRI) || !dio->submit.last_queue || - !blk_poll(dio->submit.last_queue, + !blk_mq_poll(dio->submit.last_queue, dio->submit.cookie)) io_schedule(); }