Skip to content

Commit

Permalink
NFSv4: Fix a tracepoint Oops in initiate_file_draining()
Browse files Browse the repository at this point in the history
Now that the value of 'ino' can be NULL or an ERR_PTR(), we need to
change the test in the tracepoint.

Fixes: ce5624f ("NFSv4: Return NFS4ERR_DELAY when a layout fails...")
Signed-off-by: Trond Myklebust <[email protected]>
Cc: [email protected] # v4.17+
Signed-off-by: Anna Schumaker <[email protected]>
  • Loading branch information
trondmy authored and amschuma-ntap committed Sep 14, 2018
1 parent 0af4c8b commit 2a534a7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion fs/nfs/nfs4trace.h
Original file line number Diff line number Diff line change
Expand Up @@ -1194,7 +1194,7 @@ DECLARE_EVENT_CLASS(nfs4_inode_stateid_callback_event,
TP_fast_assign(
__entry->error = error;
__entry->fhandle = nfs_fhandle_hash(fhandle);
if (inode != NULL) {
if (!IS_ERR_OR_NULL(inode)) {
__entry->fileid = NFS_FILEID(inode);
__entry->dev = inode->i_sb->s_dev;
} else {
Expand Down

0 comments on commit 2a534a7

Please sign in to comment.