Message ID | 20230203150634.3199647-18-hch@lst.de (mailing list archive) |
---|---|
State | New |
Headers | show
Return-Path: <owner-linux-mm@kvack.org> X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id E2279C6FA9E for <linux-mm@archiver.kernel.org>; Fri, 3 Feb 2023 15:08:28 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 8021B6B0092; Fri, 3 Feb 2023 10:08:21 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 6CD376B0098; Fri, 3 Feb 2023 10:08:21 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 123CF6B0092; Fri, 3 Feb 2023 10:08:21 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0012.hostedemail.com [216.40.44.12]) by kanga.kvack.org (Postfix) with ESMTP id E40EF6B0096 for <linux-mm@kvack.org>; Fri, 3 Feb 2023 10:08:20 -0500 (EST) Received: from smtpin08.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay09.hostedemail.com (Postfix) with ESMTP id 79C6881195 for <linux-mm@kvack.org>; Fri, 3 Feb 2023 15:08:20 +0000 (UTC) X-FDA: 80426311560.08.ACEB249 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) by imf11.hostedemail.com (Postfix) with ESMTP id A62FF40019 for <linux-mm@kvack.org>; Fri, 3 Feb 2023 15:08:18 +0000 (UTC) Authentication-Results: imf11.hostedemail.com; dkim=pass header.d=infradead.org header.s=bombadil.20210309 header.b=ULLWnIwz; spf=none (imf11.hostedemail.com: domain of BATV+416129e804eec9e75a33+7103+infradead.org+hch@bombadil.srs.infradead.org has no SPF policy when checking 198.137.202.133) smtp.mailfrom=BATV+416129e804eec9e75a33+7103+infradead.org+hch@bombadil.srs.infradead.org; dmarc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1675436898; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=dTKHKRVOiZxguFuEK9aGNi2iPJtbueeyhuxlyEfvmCc=; b=2VpwujVO45lBiXLYu10M0YCO4S9n+k0zuFmnHA/grqF0apHAk/Xcn3xRgtA3F8IupT0gWj wJoOjNrKd9SmLX1kNfr7iSb2NfktTFMIpqmVAFkoH+6dVhUfcwXcbDdKrgFo1/gaat4PJG E8fy5WzJZCKP1IA7aWb1xpZFcb/C2us= ARC-Authentication-Results: i=1; imf11.hostedemail.com; dkim=pass header.d=infradead.org header.s=bombadil.20210309 header.b=ULLWnIwz; spf=none (imf11.hostedemail.com: domain of BATV+416129e804eec9e75a33+7103+infradead.org+hch@bombadil.srs.infradead.org has no SPF policy when checking 198.137.202.133) smtp.mailfrom=BATV+416129e804eec9e75a33+7103+infradead.org+hch@bombadil.srs.infradead.org; dmarc=none ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1675436898; a=rsa-sha256; cv=none; b=0qn/hzwmJHgeiqh1Nayj5H1WfGTc9visy08XfT2XbSmFnS42dJFnKU1YtmzWZXVhHiWZx6 ygG1heB2cyXk+ghP4wUoKPvuhv/V8JHxZXDnCp3qGCecquMiYk8yfYpLZ0X/mpc5BJgcmi F+524BxC8yYN7rFNhch/Zo47FRFbYWE= DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender :Reply-To:Content-Type:Content-ID:Content-Description; bh=dTKHKRVOiZxguFuEK9aGNi2iPJtbueeyhuxlyEfvmCc=; b=ULLWnIwzUEY6/Q9qVLO7gvw8+M XsquPGePTfZjP71b/MLnNmfVIaXdCxfgge7DX2eGe+aN1hNlVP8iNAHk3pdpMmw6X6XyWKRLwXxD1 SaFjagBM0qpcLD4IijuTRJSPdNtwoh4gCxAi/L2yCyhGidBHFlB54moxrLT1CExRm7Qqk0oPRC3QF UztvULRJdPUYIYff571U59dCOzSWdY1aio0h51LL7NmLO9oUnqLBJjGB66OPdgeSs41hpd6cdOYoX /GPjwx4gaHfw2ikNfMjjpM+lD07l/GZC7P4wkmWbqemcZIiGRC8zjRr9UFx1SoNfbMlMuFli+EJdN XKD8CnIA==; Received: from [2001:4bb8:19a:272a:910:bb67:7287:f956] (helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1pNxf4-002b8L-GQ; Fri, 03 Feb 2023 15:07:34 +0000 From: Christoph Hellwig <hch@lst.de> To: Jens Axboe <axboe@kernel.dk> Cc: Ilya Dryomov <idryomov@gmail.com>, "Michael S. Tsirkin" <mst@redhat.com>, Jason Wang <jasowang@redhat.com>, Minchan Kim <minchan@kernel.org>, Sergey Senozhatsky <senozhatsky@chromium.org>, Keith Busch <kbusch@kernel.org>, Sagi Grimberg <sagi@grimberg.me>, Chaitanya Kulkarni <kch@nvidia.com>, "Martin K. Petersen" <martin.petersen@oracle.com>, David Howells <dhowells@redhat.com>, Marc Dionne <marc.dionne@auristor.com>, Xiubo Li <xiubli@redhat.com>, Steve French <sfrench@samba.org>, Trond Myklebust <trond.myklebust@hammerspace.com>, Anna Schumaker <anna@kernel.org>, Mike Marshall <hubcap@omnibond.com>, Andrew Morton <akpm@linux-foundation.org>, "David S. Miller" <davem@davemloft.net>, Eric Dumazet <edumazet@google.com>, Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>, Chuck Lever <chuck.lever@oracle.com>, linux-block@vger.kernel.org, ceph-devel@vger.kernel.org, virtualization@lists.linux-foundation.org, linux-nvme@lists.infradead.org, linux-scsi@vger.kernel.org, target-devel@vger.kernel.org, kvm@vger.kernel.org, netdev@vger.kernel.org, linux-afs@lists.infradead.org, linux-cifs@vger.kernel.org, samba-technical@lists.samba.org, linux-fsdevel@vger.kernel.org, linux-nfs@vger.kernel.org, devel@lists.orangefs.org, io-uring@vger.kernel.org, linux-mm@kvack.org Subject: [PATCH 17/23] splice: use bvec_set_page to initialize a bvec Date: Fri, 3 Feb 2023 16:06:28 +0100 Message-Id: <20230203150634.3199647-18-hch@lst.de> X-Mailer: git-send-email 2.39.0 In-Reply-To: <20230203150634.3199647-1-hch@lst.de> References: <20230203150634.3199647-1-hch@lst.de> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-SRS-Rewrite: SMTP reverse-path rewritten from <hch@infradead.org> by bombadil.infradead.org. See http://www.infradead.org/rpr.html X-Rspamd-Queue-Id: A62FF40019 X-Stat-Signature: darssu3uhqnbpat6mjr8hup4wbggoped X-Rspam-User: X-Rspamd-Server: rspam08 X-HE-Tag: 1675436898-147074 X-HE-Meta: U2FsdGVkX1/aQJ69ffqxK3jaZMD8ZCFb+Gvk8xQ8E6lVIE7nvQgDkA1PFk/ASENS93/2VikiSAKLVqc83ToU0ufp7cNcqcqvPTz1AvOWxkI75P14W81ULHGFnGXw4U0DRW8CoPs8oJC+RrWUIpWw+b4QGnwtz1OzFQb7Q5cfepXcCvZ1MvI5tQMEpbm+IaEJu+hxrl50UxE86Oew0lKgmhngyc853yqibfEex3CHMc+arIuOIkNMVU6bmm0pFlMRjNm3GnS1dJfvHV8Xv+6ZQehGn+oyPOoWn3CN7HfkJ9i7oQkHaSMNtvp/3mupRvXIuhC+9sZpQDuKloRYUjcCiKuF2C/lzLymbnyiCka4SQLmEm9XSf3pSCaO7+IrdVAmDdQAqq5EhMYYN4RSD2vLyDeP7DGeFNRLu2THPitZSPSUiqxm0aPSsxrbC/wK8LQwW/XyGT89I0t+ZQ64qyqmxE0iWKDHtf/lTefaQtSl7dn6nYrJ/ihVnNgRtyNVD3pWxMx8Bn2h8tQ0zPJTJUdZiqWN5Tp1JzgBzwJloXSnOOMvcdKBFFJDaYszezhpY7WrWaF3C68Sb3YLPmkKnZuUnUTfODwIOcwB5Fmka14kHWEfwmLn4NwppPprAQRPlT8x/e77tLCNnoMKeYj9Bx/MJk8D/0WW/Tf5VOzBUhxCZBxoJ4K/KsTuxCtLbFA9QRPNIrtYhEkxIudhj27UKrB6OzwalwDrU2T+RxPTIq82vZbCnEqZao8idSZPmvVNUxZQvXkeH1tBk16jgGImeicNWcM2TEQlX9bk1PGyHVyAOyxtXTZzI2m2ibpP/ICXtCVTn9o0PIOtHNxsj9VUa+Sa2msecmLokRqINrPOYwyzHOyDqy/1Ym46OP4gnNjUMHbw3AKQaimh8MdyqWmn5yMY9O+AFJy7Xp/EYRaUqUdUYJrgAkVwYbvacNF3w5a6hlYNTNrGGSgA1ZYRCKgD8Rw Wgk+4H5U /SuTi4lfKRt61knmbwUMipzrbZ0i7Nd2KfByUxyq6NDFE/1nVuXSsRUBLUifYFCotfPVqhYm63kRSoQjXmsha87Wb7gkaeH6ppgHmmsR7Kq+80/gWSZ9kSQd/KeyIVru3kLxuHE3zPdutafAyXKsa9ONMkTY0kqsev6MnMQ8Q8ODUDn092/9TOKwiK+Cf+jmF0ViQnQfeSxOq10VRIqsLDdouw7vyTt2TOd24yIFN6u+27Wk2s6bvZ0kMUMnTV6p7EWdiua5SZYS7vVRM2aJ0ZrM9cHamA1I6qlHxact++N7zgWk6i5z+68R+pgf1frmjPAhKnooI1BGRzjjrKL3A2AGxp/olPEDVcFvkbkMH6XCovnDM5dyCyvSbdXKHE8TVhoPdqJH+6G314M6XJz53l+JZPJ1OZ9+AGs03V869u2ttcXp/fia+72oBA/d5i8IQuyV4Mm5zi9rKJN0jSvPw7Sp3AISmrvmBljTp X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: <linux-mm.kvack.org> |
Series |
[01/23] block: factor out a bvec_set_page helper
|
expand
|
diff --git a/fs/splice.c b/fs/splice.c index 5969b7a1d353a8..87d9b19349de63 100644 --- a/fs/splice.c +++ b/fs/splice.c @@ -675,9 +675,8 @@ iter_file_splice_write(struct pipe_inode_info *pipe, struct file *out, goto done; } - array[n].bv_page = buf->page; - array[n].bv_len = this_len; - array[n].bv_offset = buf->offset; + bvec_set_page(&array[n], buf->page, this_len, + buf->offset); left -= this_len; n++; }
Use the bvec_set_page helper to initialize a bvec. Signed-off-by: Christoph Hellwig <hch@lst.de> --- fs/splice.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-)