From patchwork Wed Nov 6 12:35:26 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Howells X-Patchwork-Id: 13864628 Return-Path: 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 8B51FD44D54 for ; Wed, 6 Nov 2024 12:36:41 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 1D85C6B00AD; Wed, 6 Nov 2024 07:36:41 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 188E26B00AE; Wed, 6 Nov 2024 07:36:41 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 001C36B00AF; Wed, 6 Nov 2024 07:36:40 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0015.hostedemail.com [216.40.44.15]) by kanga.kvack.org (Postfix) with ESMTP id CD9976B00AD for ; Wed, 6 Nov 2024 07:36:40 -0500 (EST) Received: from smtpin04.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay06.hostedemail.com (Postfix) with ESMTP id 88008AB640 for ; Wed, 6 Nov 2024 12:36:40 +0000 (UTC) X-FDA: 82755618288.04.E1A3C05 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by imf11.hostedemail.com (Postfix) with ESMTP id 5FDB540018 for ; Wed, 6 Nov 2024 12:35:56 +0000 (UTC) Authentication-Results: imf11.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b=g69qMMoX; dmarc=pass (policy=none) header.from=redhat.com; spf=pass (imf11.hostedemail.com: domain of dhowells@redhat.com designates 170.10.133.124 as permitted sender) smtp.mailfrom=dhowells@redhat.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1730896429; a=rsa-sha256; cv=none; b=CoKXBgeCnwHgkpfpgC2QetFpxoxnkHvRCRww0PmL+ppFs8P99AZ2h4QMaJQcXDck7peSrI gPXJ4YhEZYfgDepssjoNDgZZXDxYQzYiiFtBaP9kZ58XMIKyWUp4KhAC3Nvw4sN5Kjup2J Wds0V8qRJXtuDzbaOqlrVjn7laDrEf8= ARC-Authentication-Results: i=1; imf11.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b=g69qMMoX; dmarc=pass (policy=none) header.from=redhat.com; spf=pass (imf11.hostedemail.com: domain of dhowells@redhat.com designates 170.10.133.124 as permitted sender) smtp.mailfrom=dhowells@redhat.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1730896429; 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=SueMPOdHep9t3PCuklU6bVWhougpE6WyFc4wdjmYJYc=; b=0Qr6KA+IhlPTDbREzJsF4dEubn4oErj8sMxvKI/kEoA8LgYRYrlMBnSeG8uj0vwA3vSfBj zTYkCHNtiJVS5Jbz+rjBoq3eD0N/RtACqnPi2ein1lpZMKQXzJP1fbQlWxW4JHXavrmZaE 0sL9Z3+Gpt6CT4cQQv/X7GCv5ckg4mo= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1730896598; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=SueMPOdHep9t3PCuklU6bVWhougpE6WyFc4wdjmYJYc=; b=g69qMMoXin7D8ig51MiJEZ0cxDvNM32LQIelVcPlc26eBeuXgOAthFJfyBuDkD/4Verly5 IWDiKQnfZmeZRD/6cITr7c1ZcHz8AAMs+EOlJP8T8Uu6Y8IUT32+YCdjerDEsrYRLn+KVQ Tmd3hu4RpFdzuO4DKTJr7nAMYgqtrks= Received: from mx-prod-mc-01.mail-002.prod.us-west-2.aws.redhat.com (ec2-54-186-198-63.us-west-2.compute.amazonaws.com [54.186.198.63]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-110-0fAV0xeSNeenkY30paF-Ug-1; Wed, 06 Nov 2024 07:36:32 -0500 X-MC-Unique: 0fAV0xeSNeenkY30paF-Ug-1 X-Mimecast-MFC-AGG-ID: 0fAV0xeSNeenkY30paF-Ug Received: from mx-prod-int-02.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-02.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.15]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx-prod-mc-01.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id 055B6195608F; Wed, 6 Nov 2024 12:36:29 +0000 (UTC) Received: from warthog.procyon.org.uk.com (unknown [10.42.28.231]) by mx-prod-int-02.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTP id 5C865195607C; Wed, 6 Nov 2024 12:36:22 +0000 (UTC) From: David Howells To: Christian Brauner , Steve French , Matthew Wilcox Cc: David Howells , Jeff Layton , Gao Xiang , Dominique Martinet , Marc Dionne , Paulo Alcantara , Shyam Prasad N , Tom Talpey , Eric Van Hensbergen , Ilya Dryomov , netfs@lists.linux.dev, linux-afs@lists.infradead.org, linux-cifs@vger.kernel.org, linux-nfs@vger.kernel.org, ceph-devel@vger.kernel.org, v9fs@lists.linux.dev, linux-erofs@lists.ozlabs.org, linux-fsdevel@vger.kernel.org, linux-mm@kvack.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, Christian Brauner Subject: [PATCH v3 02/33] netfs: Remove call to folio_index() Date: Wed, 6 Nov 2024 12:35:26 +0000 Message-ID: <20241106123559.724888-3-dhowells@redhat.com> In-Reply-To: <20241106123559.724888-1-dhowells@redhat.com> References: <20241106123559.724888-1-dhowells@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.0 on 10.30.177.15 X-Stat-Signature: giwud9dfxg7sceiwgq74qzxh9szqq5g7 X-Rspamd-Queue-Id: 5FDB540018 X-Rspamd-Server: rspam08 X-Rspam-User: X-HE-Tag: 1730896556-111576 X-HE-Meta: U2FsdGVkX1++U50Dce+buX9G0BJxaBPKnmjAFSiqkwfRJrPT4xebDrT5mt2mRqgmH2qXupgZFiRthwbVNZ7ABv4CiBCVmpmhodT4dS8IR9OkS3UjBvLySiXJrdvs5IWl0HP4xWnh2nKJUVyW9Byc3nU4OKOMyRlrFnnvvhSjJpz3mthmsjNwSN/HEGMvFghAKYTvFrO9R2EZLjHyA+QYQwKtRipLfd0mEqGp+1qZ5T9n6kRDzP6KAfxz9X42UM2VHaTR+QBy5LHj/FQYJQ3qSL0P85++h3hFOiYt4WIRrAUKctNpi0JKoAH4VFJQ+MQY9UUKTC2CxsNk1DTaHuwqkrb6zRyOxOnsEKw++q0wAX4NcMj5DtkSCTdE3Qj/jHvqvKuaDnN9Wo6mTvrSaP7DYb/M8ImkDwLDU1SgSAssMZsTY/6YOYR2ZhUW3MSDBOiDpHNEH5RkUvti7iH1Qug4UK/qjyi7SidemnSFQUfsyoLeG63NQ7ZxX0y3Hx3wSQmf44SRwYdEI8jGtEEAqH+Ho6XHKFSnX7Pouuw38uIpYzf3++MovkzHB4wtfarVkNmzxSRpxkvlOw0kN0crFI8DVM+MEHtdM4QoWAlVJ/lgQOcH6x/4q6FLWk9sCA2Fx089iHxwZ9ACTaYsSQQUu/rirWMopBqcNi8yDbVy71cCOWUMuCHpD09z9dwcAtGm710RIyL7WlItYtfVfD1FTfhyFtgIJAtk2VA8Hp4KKo+5NOR2K5u/BOFB7nQxOBxC0pe2Cxyz17J9jmZV+kDO5nWLdayjGsSv4aEdKIgt93jUkHJNH1Rnn8C5GcJ2nNwhtBqWfRLUtxENYXTq3LL3djZZDSUzRPgrN9ooSYFRnPUb1n0LYbuCpjrrYGV7fB25CY1nkH8gOr8GT0oumsW99kCXb+srvLoGZTrjlB28jL4bkVRFPl7TBmJSFjidw5vMjs5fj3MLNaR3TNZxFZaAB5A LXox0/B5 4Ss6OKhQoPTKNiB5jgYxXuxLIUoqZxA/VkTtvDR6v+IkIBClEfMtkg75nV5myJFmn/5M2/0C8pt1kRmrECJKEjwKQ9oz1FGYllEEVH2GOXxzADnZObjhYrYz29w3eQHW5m0Y9V5ScVviGnsXDIDbVtMiJxuv59pHZ2WUP91wm77+r4BgNLjuO7JtB215qIhvDZqQsfBLMj40S/oWICbs9bjFYHXxZyetEMbK7W6xx/lgf/ZHce6L/0YrFDKwHCJsrI02oXaoW0k/6WzCdrM1BJ9brWcu4ssr9QNZrfb9/tKYxjOHYBwOSWFTWBUmHEbbroCw6KGWVAhhNwfWmWrezH8LWKs7hBXIFLA22KbkNrjPWVDE1eyCqYrsjPB/rTRSoAExidsDskivm8zqyp/XYscEsBM2gfII8Gvgj/lEp1RovSaPyHEBNVB8cC8HKL1l4m5u6qeVPSEyZQpznqWotrm/CqeffbzA2K3oS8Lsro6QH8vcCeA+g2Cf/ZBc3/m3F85qY 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: List-Subscribe: List-Unsubscribe: From: "Matthew Wilcox (Oracle)" Calling folio_index() is pointless overhead; directly dereferencing folio->index is fine. Signed-off-by: Matthew Wilcox (Oracle) Link: https://lore.kernel.org/r/20241005182307.3190401-2-willy@infradead.org Signed-off-by: Christian Brauner --- include/trace/events/netfs.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/trace/events/netfs.h b/include/trace/events/netfs.h index 69975c9c6823..bf511bca896e 100644 --- a/include/trace/events/netfs.h +++ b/include/trace/events/netfs.h @@ -450,7 +450,7 @@ TRACE_EVENT(netfs_folio, struct address_space *__m = READ_ONCE(folio->mapping); __entry->ino = __m ? __m->host->i_ino : 0; __entry->why = why; - __entry->index = folio_index(folio); + __entry->index = folio->index; __entry->nr = folio_nr_pages(folio); ),