]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
NFSD: add cb opcode to WARN_ONCE on failed callback
authorOlga Kornievskaia <okorniev@redhat.com>
Thu, 19 Dec 2024 21:57:48 +0000 (16:57 -0500)
committerChuck Lever <chuck.lever@oracle.com>
Mon, 6 Jan 2025 14:37:40 +0000 (09:37 -0500)
It helps to know what kind of callback happened that triggered the
WARN_ONCE in nfsd4_cb_done() function in diagnosing what can set
an uncommon state where both cb_status and tk_status are set at
the same time.

Signed-off-by: Olga Kornievskaia <okorniev@redhat.com>
Reviewed-by: Jeff Layton <jlayton@kernel.org>
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
fs/nfsd/nfs4callback.c

index 151de0285d220e775e79ff0e362dfba1575e582f..a8e33f561bb344d4bd64697e4c75e95a55e0e092 100644 (file)
@@ -1396,8 +1396,9 @@ static void nfsd4_cb_done(struct rpc_task *task, void *calldata)
                return;
 
        if (cb->cb_status) {
-               WARN_ONCE(task->tk_status, "cb_status=%d tk_status=%d",
-                         cb->cb_status, task->tk_status);
+               WARN_ONCE(task->tk_status,
+                         "cb_status=%d tk_status=%d cb_opcode=%d",
+                         cb->cb_status, task->tk_status, cb->cb_ops->opcode);
                task->tk_status = cb->cb_status;
        }