Received: by 2002:a05:6a10:f3d0:0:0:0:0 with SMTP id a16csp3210601pxv; Mon, 12 Jul 2021 11:58:18 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzwyM5aPxX/pPTy8jsxCVHF2ROnXNuZ8h90V0JAzkMDd88ZSm6l1mrC/cHS8N+ISq2k3BG5 X-Received: by 2002:a17:907:3e88:: with SMTP id hs8mr581782ejc.534.1626116298422; Mon, 12 Jul 2021 11:58:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1626116298; cv=none; d=google.com; s=arc-20160816; b=ZLFutEvXbAPieCXX3q3zV1TZ03xoQ9S5fN9r/huKhAhCTMSb4wLNBZTJvp9/ANS+w2 RpwwtXex8XGNRffa5ziLSUTb6AGlwvIw/FkiQ217n0JcI5jyb8PBdwVqWAkXuyijstUO xG6Ou558oxTuguqWRRhjdTrUEWiQUw8Unz5eQhuBpUtS4QkHwl6BKcuKlDfDstiRUcYD itMXGxpgxM03k19yS2xV0kDn5aBP6e0MuhCbDcIRhW8FxkrVW2dI5WKtB/UOcezNLCbk nPpr2xv3SxPPeBxJVR6V/mSS/rOysxQ59/h4SOh0RU052981JDMzrQiYFjTQbWxIwvsS 1jkA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:message-id:date:cc:to:from:subject; bh=ivliKQW/Cwd/3aJggcqNfjQ/gjWt+NbLkmulJfDMYMk=; b=AAoJH7Ks5v4od3PgGKaNoWxkIRpv6p/q5On+gV+yNfTR0L0lViwUmVMb4twi4DBogI xQa3/eGCRSU5Xg3zOeCTPRZ8ntJAXO3Y4rC0AnUvZypx8C6/R6AqZXNGrtC6xSTO8GPZ 0fTY5qw200PcxZ5kQr9mIq27fH27mhOtIgnwy56OEwEmh0QRFQNYkmQwp52ysCVCoLFC QlzI0JhuMqvhJeJ0bde4pD4ZZb5h/CHshkpaRzxXQljDEsGSEvbM/fi7+4E0aLQT0vsk oZN9A3icMf8YIUKcGHeA75IKuhbPAL6OVWotPLs0KTuKWAYaX6ef7PgsXOP/pbDjjK2L hHVQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=oracle.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id x21si1359106ejj.704.2021.07.12.11.57.48; Mon, 12 Jul 2021 11:58:18 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=oracle.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233344AbhGLTAf (ORCPT + 99 others); Mon, 12 Jul 2021 15:00:35 -0400 Received: from mail.kernel.org ([198.145.29.99]:54244 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230409AbhGLTAf (ORCPT ); Mon, 12 Jul 2021 15:00:35 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id E2D656120A; Mon, 12 Jul 2021 18:57:46 +0000 (UTC) Subject: [PATCH v4 0/3] Bulk-release pages during NFSD read splice From: Chuck Lever To: linux-nfs@vger.kernel.org, linux-mm@kvack.org Cc: neilb@suse.de Date: Mon, 12 Jul 2021 14:57:46 -0400 Message-ID: <162611520339.1416.14646909890289253420.stgit@klimt.1015granger.net> User-Agent: StGit/1.1 MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org As with the page allocation side, I'm trying to reduce the average number of times NFSD invokes the page allocation and release APIs because they can be expensive, and because it is a resource that is shared amongst all nfsd threads and thus access to it is at least partially serialized. This small series tackles a code path that is frequently invoked when NFSD handles READ operations on local filesystems that support splice (i.e., most of the popular ones). Changes since v3: - Mark patches 1 and 3 as Reviewed-by: Neil Brown - Convert bare release_pages() calls to pagevec_release() - Release accrued free pages after every RPC retires --- Chuck Lever (3): NFSD: Clean up splice actor SUNRPC: Add svc_rqst_replace_page() API NFSD: Batch release pages during splice read fs/nfsd/vfs.c | 20 +++++--------------- include/linux/sunrpc/svc.h | 4 ++++ net/sunrpc/svc.c | 21 +++++++++++++++++++++ net/sunrpc/svc_xprt.c | 3 +++ 4 files changed, 33 insertions(+), 15 deletions(-) -- Chuck Lever