diff options
author | David Howells <dhowells@redhat.com> | 2023-11-17 09:20:28 +0000 |
---|---|---|
committer | David Howells <dhowells@redhat.com> | 2024-01-01 16:37:27 +0000 |
commit | abcbd3bfbbfe97a8912d0c929d4aa18f50d9bc52 (patch) | |
tree | 611cf56c45b7a9f6d97d78626b6daec761e69300 /include | |
parent | 28f4c58045ede40c44d331b9a6c9a6a41eb8e9a9 (diff) | |
download | linux-stable-abcbd3bfbbfe97a8912d0c929d4aa18f50d9bc52.tar.gz linux-stable-abcbd3bfbbfe97a8912d0c929d4aa18f50d9bc52.tar.bz2 linux-stable-abcbd3bfbbfe97a8912d0c929d4aa18f50d9bc52.zip |
afs: trace: Log afs_make_call(), including server address
Add a tracepoint to log calls to afs_make_call(), including the destination
server address.
Signed-off-by: David Howells <dhowells@redhat.com>
cc: Marc Dionne <marc.dionne@auristor.com>
cc: linux-afs@lists.infradead.org
Diffstat (limited to 'include')
-rw-r--r-- | include/trace/events/afs.h | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/include/trace/events/afs.h b/include/trace/events/afs.h index b2e0847eca47..5194b7e6dc8d 100644 --- a/include/trace/events/afs.h +++ b/include/trace/events/afs.h @@ -1576,6 +1576,42 @@ TRACE_EVENT(afs_rotate, __entry->extra) ); +TRACE_EVENT(afs_make_call, + TP_PROTO(struct afs_call *call), + + TP_ARGS(call), + + TP_STRUCT__entry( + __field(unsigned int, call) + __field(bool, is_vl) + __field(enum afs_fs_operation, op) + __field_struct(struct afs_fid, fid) + __field_struct(struct sockaddr_rxrpc, srx) + ), + + TP_fast_assign( + __entry->call = call->debug_id; + __entry->op = call->operation_ID; + __entry->fid = call->fid; + memcpy(&__entry->srx, rxrpc_kernel_remote_srx(call->peer), + sizeof(__entry->srx)); + __entry->srx.srx_service = call->service_id; + __entry->is_vl = (__entry->srx.srx_service == VL_SERVICE || + __entry->srx.srx_service == YFS_VL_SERVICE); + ), + + TP_printk("c=%08x %pISpc+%u %s %llx:%llx:%x", + __entry->call, + &__entry->srx.transport, + __entry->srx.srx_service, + __entry->is_vl ? + __print_symbolic(__entry->op, afs_vl_operations) : + __print_symbolic(__entry->op, afs_fs_operations), + __entry->fid.vid, + __entry->fid.vnode, + __entry->fid.unique) + ); + #endif /* _TRACE_AFS_H */ /* This part must be outside protection */ |