]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
NFSv4: Add a tracepoint for CB_LAYOUTRECALL
authorTrond Myklebust <trond.myklebust@primarydata.com>
Fri, 21 Aug 2015 01:43:14 +0000 (20:43 -0500)
committerTrond Myklebust <trond.myklebust@primarydata.com>
Tue, 25 Aug 2015 18:40:06 +0000 (14:40 -0400)
Only support for single file layoutrecall for now.

Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
fs/nfs/callback_proc.c
fs/nfs/nfs4trace.h

index 07258d269e5ae76aafa16182af4030cbb215507a..b85cf7a30232a39fb5049a098a0bde40a9563df2 100644 (file)
@@ -41,7 +41,7 @@ __be32 nfs4_callback_getattr(struct cb_getattrargs *args,
 
        inode = nfs_delegation_find_inode(cps->clp, &args->fh);
        if (inode == NULL) {
-               trace_nfs4_cb_getattr(cps->clp, &args->fh, inode,
+               trace_nfs4_cb_getattr(cps->clp, &args->fh, NULL,
                                -ntohl(res->status));
                goto out;
        }
@@ -198,6 +198,7 @@ unlock:
        spin_unlock(&ino->i_lock);
        pnfs_free_lseg_list(&free_me_list);
        pnfs_put_layout_hdr(lo);
+       trace_nfs4_cb_layoutrecall_inode(clp, &args->cbl_fh, ino, -rv);
        iput(ino);
 out:
        return rv;
index 1aa096b665dc632b4153a12250587dce53f679c0..28df12e525bac5857c0d41aba62d558db82f526a 100644 (file)
@@ -941,6 +941,7 @@ DECLARE_EVENT_CLASS(nfs4_inode_callback_event,
                        ), \
                        TP_ARGS(clp, fhandle, inode, error))
 DEFINE_NFS4_INODE_CALLBACK_EVENT(nfs4_cb_getattr);
+DEFINE_NFS4_INODE_CALLBACK_EVENT(nfs4_cb_layoutrecall_inode);
 
 
 DECLARE_EVENT_CLASS(nfs4_idmap_event,