All of lore.kernel.org
 help / color / mirror / Atom feed
From: Chuck Lever <chuck.lever@oracle.com>
To: linux-nfs@vger.kernel.org
Cc: dwysocha@redhat.com, bfields@fieldses.org
Subject: [PATCH v3 16/24] NFSD: Adjust cb_shutdown tracepoint
Date: Fri, 14 May 2021 15:56:49 -0400	[thread overview]
Message-ID: <162102220985.10915.14015767336113364759.stgit@klimt.1015granger.net> (raw)
In-Reply-To: <162102191240.10915.5003178983503027218.stgit@klimt.1015granger.net>

Show when the upper layer requested a shutdown. RPC tracepoints can
already show when rpc_shutdown_client() is called.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
---
 fs/nfsd/nfs4callback.c |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/fs/nfsd/nfs4callback.c b/fs/nfsd/nfs4callback.c
index b6cc51a9f37c..ab1836381e22 100644
--- a/fs/nfsd/nfs4callback.c
+++ b/fs/nfsd/nfs4callback.c
@@ -1233,6 +1233,9 @@ void nfsd4_destroy_callback_queue(void)
 /* must be called under the state lock */
 void nfsd4_shutdown_callback(struct nfs4_client *clp)
 {
+	if (clp->cl_cb_state != NFSD4_CB_UNKNOWN)
+		trace_nfsd_cb_shutdown(clp);
+
 	set_bit(NFSD4_CLIENT_CB_KILL, &clp->cl_flags);
 	/*
 	 * Note this won't actually result in a null callback;
@@ -1278,7 +1281,6 @@ static void nfsd4_process_cb_update(struct nfsd4_callback *cb)
 	 * kill the old client:
 	 */
 	if (clp->cl_cb_client) {
-		trace_nfsd_cb_shutdown(clp);
 		rpc_shutdown_client(clp->cl_cb_client);
 		clp->cl_cb_client = NULL;
 		put_cred(clp->cl_cb_cred);



  parent reply	other threads:[~2021-05-14 19:56 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-14 19:55 [PATCH v3 00/24] NFSD callback and lease management observability Chuck Lever
2021-05-14 19:55 ` [PATCH v3 01/24] NFSD: Fix TP_printk() format specifier in nfsd_clid_class Chuck Lever
2021-05-14 19:55 ` [PATCH v3 02/24] NFSD: Add an RPC authflavor tracepoint display helper Chuck Lever
2021-05-14 19:55 ` [PATCH v3 03/24] NFSD: Add nfsd_clid_cred_mismatch tracepoint Chuck Lever
2021-05-14 19:55 ` [PATCH v3 04/24] NFSD: Add nfsd_clid_verf_mismatch tracepoint Chuck Lever
2021-05-14 19:55 ` [PATCH v3 05/24] NFSD: Remove trace_nfsd_clid_inuse_err Chuck Lever
2021-05-14 19:55 ` [PATCH v3 06/24] NFSD: Add nfsd_clid_confirmed tracepoint Chuck Lever
2021-05-14 19:55 ` [PATCH v3 07/24] NFSD: Add nfsd_clid_reclaim_complete tracepoint Chuck Lever
2021-05-14 19:56 ` [PATCH v3 08/24] NFSD: Add nfsd_clid_destroyed tracepoint Chuck Lever
2021-05-14 19:56 ` [PATCH v3 09/24] NFSD: Add a couple more nfsd_clid_expired call sites Chuck Lever
2021-05-14 19:56 ` [PATCH v3 10/24] NFSD: Add tracepoints for SETCLIENTID edge cases Chuck Lever
2021-05-14 19:56 ` [PATCH v3 11/24] NFSD: Add tracepoints for EXCHANGEID " Chuck Lever
2021-05-14 19:56 ` [PATCH v3 12/24] NFSD: Constify @fh argument of knfsd_fh_hash() Chuck Lever
2021-05-14 19:56 ` [PATCH v3 13/24] NFSD: Capture every CB state transition Chuck Lever
2021-05-14 19:56 ` [PATCH v3 14/24] NFSD: Drop TRACE_DEFINE_ENUM for NFSD4_CB_<state> macros Chuck Lever
2021-05-14 19:56 ` [PATCH v3 15/24] NFSD: Add cb_lost tracepoint Chuck Lever
2021-05-14 19:56 ` Chuck Lever [this message]
2021-05-14 19:56 ` [PATCH v3 17/24] NFSD: Remove spurious cb_setup_err tracepoint Chuck Lever
2021-05-14 19:57 ` [PATCH v3 18/24] NFSD: Enhance the nfsd_cb_setup tracepoint Chuck Lever
2021-05-14 19:57 ` [PATCH v3 19/24] NFSD: Add an nfsd_cb_lm_notify tracepoint Chuck Lever
2021-05-14 19:57 ` [PATCH v3 20/24] NFSD: Add an nfsd_cb_offload tracepoint Chuck Lever
2021-05-14 19:57 ` [PATCH v3 21/24] NFSD: Replace the nfsd_deleg_break tracepoint Chuck Lever
2021-05-14 19:57 ` [PATCH v3 22/24] NFSD: Add an nfsd_cb_probe tracepoint Chuck Lever
2021-05-14 19:57 ` [PATCH v3 23/24] NFSD: Remove the nfsd_cb_work and nfsd_cb_done tracepoints Chuck Lever
2021-05-14 19:57 ` [PATCH v3 24/24] NFSD: Update nfsd_cb_args tracepoint Chuck Lever

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=162102220985.10915.14015767336113364759.stgit@klimt.1015granger.net \
    --to=chuck.lever@oracle.com \
    --cc=bfields@fieldses.org \
    --cc=dwysocha@redhat.com \
    --cc=linux-nfs@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.