Commit ba017fd3 authored by Jeff Layton's avatar Jeff Layton Committed by Chuck Lever
Browse files

nfsd: add more nfsd_cb tracepoints



Add some tracepoints in the callback client RPC operations. Also
add a tracepoint to nfsd4_cb_getattr_done.

Signed-off-by: default avatarJeff Layton <jlayton@kernel.org>
Signed-off-by: default avatarChuck Lever <chuck.lever@oracle.com>
parent c1c9f3ea
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -1223,6 +1223,7 @@ static void nfsd4_cb_prepare(struct rpc_task *task, void *calldata)
	 * cb_seq_status is only set in decode_cb_sequence4res,
	 * and so will remain 1 if an rpc level failure occurs.
	 */
	trace_nfsd_cb_rpc_prepare(clp);
	cb->cb_seq_status = 1;
	cb->cb_status = 0;
	if (minorversion && !nfsd41_cb_get_slot(cb, task))
@@ -1329,6 +1330,8 @@ static void nfsd4_cb_done(struct rpc_task *task, void *calldata)
	struct nfsd4_callback *cb = calldata;
	struct nfs4_client *clp = cb->cb_clp;

	trace_nfsd_cb_rpc_done(clp);

	if (!nfsd4_cb_sequence_done(task, cb))
		return;

@@ -1360,6 +1363,8 @@ static void nfsd4_cb_release(void *calldata)
{
	struct nfsd4_callback *cb = calldata;

	trace_nfsd_cb_rpc_release(cb->cb_clp);

	if (cb->cb_need_restart)
		nfsd4_queue_cb(cb);
	else
+3 −0
Original line number Diff line number Diff line
@@ -3057,7 +3057,10 @@ nfsd4_cb_getattr_done(struct nfsd4_callback *cb, struct rpc_task *task)
{
	struct nfs4_cb_fattr *ncf =
			container_of(cb, struct nfs4_cb_fattr, ncf_getattr);
	struct nfs4_delegation *dp =
			container_of(ncf, struct nfs4_delegation, dl_cb_fattr);

	trace_nfsd_cb_getattr_done(&dp->dl_stid.sc_stateid, task);
	ncf->ncf_cb_status = task->tk_status;
	switch (task->tk_status) {
	case -NFS4ERR_DELAY:
+4 −0
Original line number Diff line number Diff line
@@ -1486,6 +1486,9 @@ DEFINE_NFSD_CB_EVENT(new_state);
DEFINE_NFSD_CB_EVENT(probe);
DEFINE_NFSD_CB_EVENT(lost);
DEFINE_NFSD_CB_EVENT(shutdown);
DEFINE_NFSD_CB_EVENT(rpc_prepare);
DEFINE_NFSD_CB_EVENT(rpc_done);
DEFINE_NFSD_CB_EVENT(rpc_release);

TRACE_DEFINE_ENUM(RPC_AUTH_NULL);
TRACE_DEFINE_ENUM(RPC_AUTH_UNIX);
@@ -1845,6 +1848,7 @@ DEFINE_NFSD_CB_DONE_EVENT(nfsd_cb_recall_done);
DEFINE_NFSD_CB_DONE_EVENT(nfsd_cb_notify_lock_done);
DEFINE_NFSD_CB_DONE_EVENT(nfsd_cb_layout_done);
DEFINE_NFSD_CB_DONE_EVENT(nfsd_cb_offload_done);
DEFINE_NFSD_CB_DONE_EVENT(nfsd_cb_getattr_done);

TRACE_EVENT(nfsd_cb_recall_any_done,
	TP_PROTO(