Received: by 2002:a05:6a10:9afc:0:0:0:0 with SMTP id t28csp484045pxm; Fri, 25 Feb 2022 11:59:38 -0800 (PST) X-Google-Smtp-Source: ABdhPJzC4+aafk78MIICbT0o3Mv6+8ofBdscTNlQv+WwSVfXcBHm66niIO4kY+eQAbkqXybywzr5 X-Received: by 2002:a63:b47:0:b0:373:cbfb:f4c8 with SMTP id a7-20020a630b47000000b00373cbfbf4c8mr7262540pgl.328.1645819178205; Fri, 25 Feb 2022 11:59:38 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1645819178; cv=none; d=google.com; s=arc-20160816; b=PazDXTbblu+A7mkLJ96kWU1gGWp6yGxOj9+gWSvT+PfBjZOYnvK1/+qt/E1dVG2AZr ZCm7Y3Gg81uWUQhl+0RuOrjxCcmtVP5gu/006pX972HSdSWrVnsWNL6vIAoZYSz8aYmT 8zDTBMPg6qXpYzrMSyXPJopnl/Ds+UX4SPPiFxMbriBq0OB/nz6IvkVMMyP7Qve3C4ZY L/LQDR9Ld7cTq6xVex3HQySkgCqcmYuY/oir/aS+Jf4PBZzXnPwFA4hchd07nLSMPgEE 5C6/IwP662GSgpluY40w3e4Prdxi4tqc9T4+VPJRxOBBS4TpXEx/gUsyR16SKs8FTE6Y 1I7g== 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 :references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=2Ht5xT9ejdjxifq3zc1/jWgmCK7BzTHXwBDUsszmDhI=; b=TihlkbRBtuLzxbUVVfdf39+33/xjSBhF16iS6anfhBj1u8RIINLrnCVr346Q85MKIG u81m62kZ27PkPsWjBRj8vFF0tFTV7Gym3ppcDEQEnD27Q6+xTFRXbDJRVgQLZ794Ken9 LWKXnPIwqAYkmK5dht4ticv8a2JwnPPJXtnFt3dsW9WJZrwvWyD2LMb6180GXTu0iXEt xgoLqq8pNJfwid2bv57aMEhUV5i6HhL1cfb4TysyIRYRfDChEsdUpC9Xn2TqvdcRG1Id bR2SHh+is4S5rA9+Xo2akPhTU3MUIGyP36oJyNQOH76OwZvEBxDtC+Vd7NL/kLXX0/Cz thGg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=KptbVm8h; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id m20-20020a170902bb9400b0014f92171f08si2545645pls.439.2022.02.25.11.59.04; Fri, 25 Feb 2022 11:59:38 -0800 (PST) Received-SPF: pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=KptbVm8h; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233355AbiBYSfX (ORCPT + 99 others); Fri, 25 Feb 2022 13:35:23 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47272 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233397AbiBYSfR (ORCPT ); Fri, 25 Feb 2022 13:35:17 -0500 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 78C9E1B65D8 for ; Fri, 25 Feb 2022 10:34:44 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 1E1E0B83309 for ; Fri, 25 Feb 2022 18:34:44 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 944D4C340F1 for ; Fri, 25 Feb 2022 18:34:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1645814083; bh=/Hh4ZDVLddAewg5KmSMUDCPnN6eJUtFDtuBUz+0xNek=; h=From:To:Subject:Date:In-Reply-To:References:From; b=KptbVm8hwLb+DfHvw+n9k5LS9+jG0h7FnB2OLPp75oKbNZlaC4/6KEA/wOL3SL0T3 7dxolkBRQ8yOyjuzyIPys0sTJyIpVrrx8TxcrzJK+znIG4EgobzQfrjIM7ZNWe3xpa 1Cc411/rEry1NXsd5hJJ7KAYXRn7LXWmWvkyi0JmoztgAIOkXnYU75W7VucY+ptB+9 eOoWkrPePy0lXIZn0N8jJ+4Bj3McLD+JU8FwVyiXZ+30cmdo8H2yhOWtLJYKSiSOfI sux9iHzmtDO9UL8qmMvtWbjP3sVad2ZnzDkMVVMBvdoa52Iukqidvq93GLNOGfq5OF prqrPVK+6595A== From: trondmy@kernel.org To: linux-nfs@vger.kernel.org Subject: [PATCH v8 19/24] NFS: Trace effects of readdirplus on the dcache Date: Fri, 25 Feb 2022 13:28:24 -0500 Message-Id: <20220225182829.1236093-20-trondmy@kernel.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20220225182829.1236093-19-trondmy@kernel.org> References: <20220225182829.1236093-1-trondmy@kernel.org> <20220225182829.1236093-2-trondmy@kernel.org> <20220225182829.1236093-3-trondmy@kernel.org> <20220225182829.1236093-4-trondmy@kernel.org> <20220225182829.1236093-5-trondmy@kernel.org> <20220225182829.1236093-6-trondmy@kernel.org> <20220225182829.1236093-7-trondmy@kernel.org> <20220225182829.1236093-8-trondmy@kernel.org> <20220225182829.1236093-9-trondmy@kernel.org> <20220225182829.1236093-10-trondmy@kernel.org> <20220225182829.1236093-11-trondmy@kernel.org> <20220225182829.1236093-12-trondmy@kernel.org> <20220225182829.1236093-13-trondmy@kernel.org> <20220225182829.1236093-14-trondmy@kernel.org> <20220225182829.1236093-15-trondmy@kernel.org> <20220225182829.1236093-16-trondmy@kernel.org> <20220225182829.1236093-17-trondmy@kernel.org> <20220225182829.1236093-18-trondmy@kernel.org> <20220225182829.1236093-19-trondmy@kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org From: Trond Myklebust Trace the effects of readdirplus on attribute and dentry revalidation. Signed-off-by: Trond Myklebust --- fs/nfs/dir.c | 5 +++++ fs/nfs/nfstrace.h | 3 +++ 2 files changed, 8 insertions(+) diff --git a/fs/nfs/dir.c b/fs/nfs/dir.c index 9fc584c11e70..fa32eb5f6391 100644 --- a/fs/nfs/dir.c +++ b/fs/nfs/dir.c @@ -742,8 +742,12 @@ void nfs_prime_dcache(struct dentry *parent, struct nfs_entry *entry, status = nfs_refresh_inode(d_inode(dentry), entry->fattr); if (!status) nfs_setsecurity(d_inode(dentry), entry->fattr); + trace_nfs_readdir_lookup_revalidate(d_inode(parent), + dentry, 0, status); goto out; } else { + trace_nfs_readdir_lookup_revalidate_failed( + d_inode(parent), dentry, 0); d_invalidate(dentry); dput(dentry); dentry = NULL; @@ -765,6 +769,7 @@ void nfs_prime_dcache(struct dentry *parent, struct nfs_entry *entry, dentry = alias; } nfs_set_verifier(dentry, dir_verifier); + trace_nfs_readdir_lookup(d_inode(parent), dentry, 0); out: dput(dentry); } diff --git a/fs/nfs/nfstrace.h b/fs/nfs/nfstrace.h index c2d0543ecb2d..7c1102b991d0 100644 --- a/fs/nfs/nfstrace.h +++ b/fs/nfs/nfstrace.h @@ -432,6 +432,9 @@ DEFINE_NFS_LOOKUP_EVENT(nfs_lookup_enter); DEFINE_NFS_LOOKUP_EVENT_DONE(nfs_lookup_exit); DEFINE_NFS_LOOKUP_EVENT(nfs_lookup_revalidate_enter); DEFINE_NFS_LOOKUP_EVENT_DONE(nfs_lookup_revalidate_exit); +DEFINE_NFS_LOOKUP_EVENT(nfs_readdir_lookup); +DEFINE_NFS_LOOKUP_EVENT(nfs_readdir_lookup_revalidate_failed); +DEFINE_NFS_LOOKUP_EVENT_DONE(nfs_readdir_lookup_revalidate); TRACE_EVENT(nfs_atomic_open_enter, TP_PROTO( -- 2.35.1