From patchwork Thu Jun 15 03:45:10 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jens Axboe X-Patchwork-Id: 9788023 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 8576460384 for ; Thu, 15 Jun 2017 03:45:47 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 7A1E9285C2 for ; Thu, 15 Jun 2017 03:45:47 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 687AA285B3; Thu, 15 Jun 2017 03:45:47 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id D785A28589 for ; Thu, 15 Jun 2017 03:45:45 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752108AbdFODph (ORCPT ); Wed, 14 Jun 2017 23:45:37 -0400 Received: from mail-pg0-f46.google.com ([74.125.83.46]:32806 "EHLO mail-pg0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752088AbdFODpg (ORCPT ); Wed, 14 Jun 2017 23:45:36 -0400 Received: by mail-pg0-f46.google.com with SMTP id f185so1675616pgc.0 for ; Wed, 14 Jun 2017 20:45:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel-dk.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=nWIG05tGbkuJQh190c7vKYEJYV3hJzGfe+mImz3se/M=; b=It6dB+M7qqq8dN2+WmVK6yR1EPorSPgHRjV//8CbH2EZnNMgjATc/7v1KYm1Yo9Vjw 5Y2+GPXFea9chmfUGrCLjKkIEsfdtT8x3Oxtk9ZSYyF7curT9hpSezg032G/Tlt93AD3 FVXJb5aNRxzuIq5suJ4ZPnml6KshrH/hrNDVGjphS2Y8259Ly/5NQrVAKanZKmRyCM/z 1UO7+i7+eqJsISRDpyDJur5Trz2csZX1bpd7XqMWYqtFygkxGPVTc9b+cVn1904aIGnI jDWgRI+I89kg2QaW4qRV359mrw1NRQDQr6wrHLR7Yid3YlaltjH6lXq4dzSRGWySjsxt gvZg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=nWIG05tGbkuJQh190c7vKYEJYV3hJzGfe+mImz3se/M=; b=tutFq+sq8TnxmUwgfgv8NZvf2KgG6SocVl9B+mIXfuEQtiAAHxUVdOUUBwR+ovc1Dk uTDQLtfVnD/b7mRihC42gjCDrtFrBf04gtOXzwRCjdSfsxzdGbB7BgzN4eK6ZD5Cnsuc ZbL5YoSYKEnHPDYc7LdEUJ+2JpMEihqPQHrquXo+puruMRxdV5k9dfr3zaDxza2tWWdc SIkauaYSC9z4WvajsV1trlXRiAXlze0V7W+IBqqPYw7d6tv69l6Meb1AJfqMNoeK4tLD 0LVbLnVQzHKjrYVtQQAeM8/5o7fFIlv6XEynrcW9SNXUGTDngyUKV/pgn2tH2zZh60Ww 56cw== X-Gm-Message-State: AKS2vOwr0qrBymxUm9b7HQozqk1OZcAuvllj4WNN4Jb0TpTR/pJ0DQ0R JTb+kqFTNTXIEZ+pkvEDAQ== X-Received: by 10.84.201.74 with SMTP id t10mr3769266plh.44.1497498335510; Wed, 14 Jun 2017 20:45:35 -0700 (PDT) Received: from localhost.localdomain (66.29.164.166.static.utbb.net. [66.29.164.166]) by smtp.gmail.com with ESMTPSA id f71sm2532627pfd.98.2017.06.14.20.45.34 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 14 Jun 2017 20:45:34 -0700 (PDT) From: Jens Axboe To: linux-fsdevel@vger.kernel.org, linux-block@vger.kernel.org Cc: adilger@dilger.ca, hch@infradead.org, martin.petersen@oracle.com, Jens Axboe Subject: [PATCH 09/11] xfs: add support for passing in write hints for buffered writes Date: Wed, 14 Jun 2017 21:45:10 -0600 Message-Id: <1497498312-17704-10-git-send-email-axboe@kernel.dk> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1497498312-17704-1-git-send-email-axboe@kernel.dk> References: <1497498312-17704-1-git-send-email-axboe@kernel.dk> Sender: linux-fsdevel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fsdevel@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Reviewed-by: Andreas Dilger Signed-off-by: Jens Axboe --- fs/xfs/xfs_aops.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/fs/xfs/xfs_aops.c b/fs/xfs/xfs_aops.c index 09af0f7cd55e..fe11fe47d235 100644 --- a/fs/xfs/xfs_aops.c +++ b/fs/xfs/xfs_aops.c @@ -505,6 +505,7 @@ xfs_submit_ioend( return status; } + ioend->io_bio->bi_opf |= bio_op_write_hint(inode_write_hint(ioend->io_inode)); submit_bio(ioend->io_bio); return 0; } @@ -564,6 +565,7 @@ xfs_chain_bio( bio_chain(ioend->io_bio, new); bio_get(ioend->io_bio); /* for xfs_destroy_ioend */ ioend->io_bio->bi_opf = REQ_OP_WRITE | wbc_to_write_flags(wbc); + ioend->io_bio->bi_opf |= bio_op_write_hint(inode_write_hint(ioend->io_inode)); submit_bio(ioend->io_bio); ioend->io_bio = new; }