rxrpc: Change rx_packet tracepoint to display securityIndex not type twice
[linux-block.git] / include / trace / events / rxrpc.h
CommitLineData
b4d0d230 1/* SPDX-License-Identifier: GPL-2.0-or-later */
df844fd4
DH
2/* AF_RXRPC tracepoints
3 *
4 * Copyright (C) 2016 Red Hat, Inc. All Rights Reserved.
5 * Written by David Howells (dhowells@redhat.com)
df844fd4
DH
6 */
7#undef TRACE_SYSTEM
8#define TRACE_SYSTEM rxrpc
9
10#if !defined(_TRACE_RXRPC_H) || defined(TRACE_HEADER_MULTI_READ)
11#define _TRACE_RXRPC_H
12
13#include <linux/tracepoint.h>
494337c9 14#include <linux/errqueue.h>
df844fd4 15
b54a134a
DH
16/*
17 * Declare tracing information enums and their string mappings for display.
18 */
57af281e
DH
19#define rxrpc_abort_reasons \
20 /* AFS errors */ \
21 EM(afs_abort_general_error, "afs-error") \
22 EM(afs_abort_interrupted, "afs-intr") \
23 EM(afs_abort_oom, "afs-oom") \
24 EM(afs_abort_op_not_supported, "afs-op-notsupp") \
25 EM(afs_abort_probeuuid_negative, "afs-probeuuid-neg") \
26 EM(afs_abort_send_data_error, "afs-send-data") \
27 EM(afs_abort_unmarshal_error, "afs-unmarshal") \
28 /* rxperf errors */ \
29 EM(rxperf_abort_general_error, "rxperf-error") \
30 EM(rxperf_abort_oom, "rxperf-oom") \
31 EM(rxperf_abort_op_not_supported, "rxperf-op-notsupp") \
32 EM(rxperf_abort_unmarshal_error, "rxperf-unmarshal") \
33 /* RxKAD security errors */ \
34 EM(rxkad_abort_1_short_check, "rxkad1-short-check") \
35 EM(rxkad_abort_1_short_data, "rxkad1-short-data") \
36 EM(rxkad_abort_1_short_encdata, "rxkad1-short-encdata") \
37 EM(rxkad_abort_1_short_header, "rxkad1-short-hdr") \
38 EM(rxkad_abort_2_short_check, "rxkad2-short-check") \
39 EM(rxkad_abort_2_short_data, "rxkad2-short-data") \
40 EM(rxkad_abort_2_short_header, "rxkad2-short-hdr") \
41 EM(rxkad_abort_2_short_len, "rxkad2-short-len") \
42 EM(rxkad_abort_bad_checksum, "rxkad2-bad-cksum") \
43 EM(rxkad_abort_chall_key_expired, "rxkad-chall-key-exp") \
44 EM(rxkad_abort_chall_level, "rxkad-chall-level") \
45 EM(rxkad_abort_chall_no_key, "rxkad-chall-nokey") \
46 EM(rxkad_abort_chall_short, "rxkad-chall-short") \
47 EM(rxkad_abort_chall_version, "rxkad-chall-version") \
48 EM(rxkad_abort_resp_bad_callid, "rxkad-resp-bad-callid") \
49 EM(rxkad_abort_resp_bad_checksum, "rxkad-resp-bad-cksum") \
50 EM(rxkad_abort_resp_bad_param, "rxkad-resp-bad-param") \
51 EM(rxkad_abort_resp_call_ctr, "rxkad-resp-call-ctr") \
52 EM(rxkad_abort_resp_call_state, "rxkad-resp-call-state") \
53 EM(rxkad_abort_resp_key_expired, "rxkad-resp-key-exp") \
54 EM(rxkad_abort_resp_key_rejected, "rxkad-resp-key-rej") \
55 EM(rxkad_abort_resp_level, "rxkad-resp-level") \
56 EM(rxkad_abort_resp_nokey, "rxkad-resp-nokey") \
57 EM(rxkad_abort_resp_ooseq, "rxkad-resp-ooseq") \
58 EM(rxkad_abort_resp_short, "rxkad-resp-short") \
59 EM(rxkad_abort_resp_short_tkt, "rxkad-resp-short-tkt") \
60 EM(rxkad_abort_resp_tkt_aname, "rxkad-resp-tk-aname") \
61 EM(rxkad_abort_resp_tkt_expired, "rxkad-resp-tk-exp") \
62 EM(rxkad_abort_resp_tkt_future, "rxkad-resp-tk-future") \
63 EM(rxkad_abort_resp_tkt_inst, "rxkad-resp-tk-inst") \
64 EM(rxkad_abort_resp_tkt_len, "rxkad-resp-tk-len") \
65 EM(rxkad_abort_resp_tkt_realm, "rxkad-resp-tk-realm") \
66 EM(rxkad_abort_resp_tkt_short, "rxkad-resp-tk-short") \
67 EM(rxkad_abort_resp_tkt_sinst, "rxkad-resp-tk-sinst") \
68 EM(rxkad_abort_resp_tkt_sname, "rxkad-resp-tk-sname") \
69 EM(rxkad_abort_resp_unknown_tkt, "rxkad-resp-unknown-tkt") \
70 EM(rxkad_abort_resp_version, "rxkad-resp-version") \
71 /* rxrpc errors */ \
72 EM(rxrpc_abort_call_improper_term, "call-improper-term") \
73 EM(rxrpc_abort_call_reset, "call-reset") \
74 EM(rxrpc_abort_call_sendmsg, "call-sendmsg") \
75 EM(rxrpc_abort_call_sock_release, "call-sock-rel") \
76 EM(rxrpc_abort_call_sock_release_tba, "call-sock-rel-tba") \
77 EM(rxrpc_abort_call_timeout, "call-timeout") \
78 EM(rxrpc_abort_no_service_key, "no-serv-key") \
79 EM(rxrpc_abort_nomem, "nomem") \
80 EM(rxrpc_abort_service_not_offered, "serv-not-offered") \
81 EM(rxrpc_abort_shut_down, "shut-down") \
82 EM(rxrpc_abort_unsupported_security, "unsup-sec") \
83 EM(rxrpc_badmsg_bad_abort, "bad-abort") \
84 EM(rxrpc_badmsg_bad_jumbo, "bad-jumbo") \
85 EM(rxrpc_badmsg_short_ack, "short-ack") \
86 EM(rxrpc_badmsg_short_ack_info, "short-ack-info") \
87 EM(rxrpc_badmsg_short_hdr, "short-hdr") \
88 EM(rxrpc_badmsg_unsupported_packet, "unsup-pkt") \
89 EM(rxrpc_badmsg_zero_call, "zero-call") \
90 EM(rxrpc_badmsg_zero_seq, "zero-seq") \
91 EM(rxrpc_badmsg_zero_service, "zero-service") \
92 EM(rxrpc_eproto_ackr_outside_window, "ackr-out-win") \
93 EM(rxrpc_eproto_ackr_sack_overflow, "ackr-sack-over") \
94 EM(rxrpc_eproto_ackr_short_sack, "ackr-short-sack") \
95 EM(rxrpc_eproto_ackr_zero, "ackr-zero") \
96 EM(rxrpc_eproto_bad_upgrade, "bad-upgrade") \
97 EM(rxrpc_eproto_data_after_last, "data-after-last") \
98 EM(rxrpc_eproto_different_last, "diff-last") \
99 EM(rxrpc_eproto_early_reply, "early-reply") \
100 EM(rxrpc_eproto_improper_term, "improper-term") \
101 EM(rxrpc_eproto_no_client_call, "no-cl-call") \
102 EM(rxrpc_eproto_no_client_conn, "no-cl-conn") \
103 EM(rxrpc_eproto_no_service_call, "no-sv-call") \
104 EM(rxrpc_eproto_reupgrade, "re-upgrade") \
105 EM(rxrpc_eproto_rxnull_challenge, "rxnull-chall") \
106 EM(rxrpc_eproto_rxnull_response, "rxnull-resp") \
107 EM(rxrpc_eproto_tx_rot_last, "tx-rot-last") \
108 EM(rxrpc_eproto_unexpected_ack, "unex-ack") \
109 EM(rxrpc_eproto_unexpected_ackall, "unex-ackall") \
110 EM(rxrpc_eproto_unexpected_implicit_end, "unex-impl-end") \
111 EM(rxrpc_eproto_unexpected_reply, "unex-reply") \
112 EM(rxrpc_eproto_wrong_security, "wrong-sec") \
113 EM(rxrpc_recvmsg_excess_data, "recvmsg-excess") \
114 EM(rxrpc_recvmsg_short_data, "recvmsg-short") \
115 E_(rxrpc_sendmsg_late_send, "sendmsg-late")
116
15f661dc 117#define rxrpc_call_poke_traces \
a343b174 118 EM(rxrpc_call_poke_abort, "Abort") \
03fc55ad 119 EM(rxrpc_call_poke_complete, "Compl") \
15f661dc
DH
120 EM(rxrpc_call_poke_error, "Error") \
121 EM(rxrpc_call_poke_idle, "Idle") \
122 EM(rxrpc_call_poke_start, "Start") \
123 EM(rxrpc_call_poke_timer, "Timer") \
124 E_(rxrpc_call_poke_timer_now, "Timer-now")
125
b54a134a 126#define rxrpc_skb_traces \
9a36a6bc
DH
127 EM(rxrpc_skb_eaten_by_unshare, "ETN unshare ") \
128 EM(rxrpc_skb_eaten_by_unshare_nomem, "ETN unshar-nm") \
2953d3b8 129 EM(rxrpc_skb_get_conn_secured, "GET conn-secd") \
9a36a6bc 130 EM(rxrpc_skb_get_conn_work, "GET conn-work") \
2d1faf7a
DH
131 EM(rxrpc_skb_get_local_work, "GET locl-work") \
132 EM(rxrpc_skb_get_reject_work, "GET rej-work ") \
9a36a6bc
DH
133 EM(rxrpc_skb_get_to_recvmsg, "GET to-recv ") \
134 EM(rxrpc_skb_get_to_recvmsg_oos, "GET to-recv-o") \
135 EM(rxrpc_skb_new_encap_rcv, "NEW encap-rcv") \
136 EM(rxrpc_skb_new_error_report, "NEW error-rpt") \
137 EM(rxrpc_skb_new_jumbo_subpacket, "NEW jumbo-sub") \
138 EM(rxrpc_skb_new_unshared, "NEW unshared ") \
2953d3b8 139 EM(rxrpc_skb_put_conn_secured, "PUT conn-secd") \
9a36a6bc
DH
140 EM(rxrpc_skb_put_conn_work, "PUT conn-work") \
141 EM(rxrpc_skb_put_error_report, "PUT error-rep") \
142 EM(rxrpc_skb_put_input, "PUT input ") \
143 EM(rxrpc_skb_put_jumbo_subpacket, "PUT jumbo-sub") \
9a36a6bc
DH
144 EM(rxrpc_skb_put_purge, "PUT purge ") \
145 EM(rxrpc_skb_put_rotate, "PUT rotate ") \
146 EM(rxrpc_skb_put_unknown, "PUT unknown ") \
147 EM(rxrpc_skb_see_conn_work, "SEE conn-work") \
9a36a6bc
DH
148 EM(rxrpc_skb_see_recvmsg, "SEE recvmsg ") \
149 EM(rxrpc_skb_see_reject, "SEE reject ") \
150 EM(rxrpc_skb_see_rotate, "SEE rotate ") \
151 E_(rxrpc_skb_see_version, "SEE version ")
b54a134a 152
09d2bf59 153#define rxrpc_local_traces \
0fde882f 154 EM(rxrpc_local_free, "FREE ") \
f3441d41 155 EM(rxrpc_local_get_call, "GET call ") \
0fde882f
DH
156 EM(rxrpc_local_get_client_conn, "GET conn-cln") \
157 EM(rxrpc_local_get_for_use, "GET for-use ") \
158 EM(rxrpc_local_get_peer, "GET peer ") \
159 EM(rxrpc_local_get_prealloc_conn, "GET conn-pre") \
0fde882f 160 EM(rxrpc_local_new, "NEW ") \
0fde882f 161 EM(rxrpc_local_put_bind, "PUT bind ") \
f3441d41 162 EM(rxrpc_local_put_call, "PUT call ") \
0fde882f
DH
163 EM(rxrpc_local_put_for_use, "PUT for-use ") \
164 EM(rxrpc_local_put_kill_conn, "PUT conn-kil") \
165 EM(rxrpc_local_put_peer, "PUT peer ") \
8395406b 166 EM(rxrpc_local_put_prealloc_peer, "PUT peer-pre") \
0fde882f 167 EM(rxrpc_local_put_release_sock, "PUT rel-sock") \
0fde882f
DH
168 EM(rxrpc_local_stop, "STOP ") \
169 EM(rxrpc_local_stopped, "STOPPED ") \
170 EM(rxrpc_local_unuse_bind, "UNU bind ") \
171 EM(rxrpc_local_unuse_conn_work, "UNU conn-wrk") \
172 EM(rxrpc_local_unuse_peer_keepalive, "UNU peer-kpa") \
173 EM(rxrpc_local_unuse_release_sock, "UNU rel-sock") \
0fde882f
DH
174 EM(rxrpc_local_use_conn_work, "USE conn-wrk") \
175 EM(rxrpc_local_use_lookup, "USE lookup ") \
5e6ef4f1 176 E_(rxrpc_local_use_peer_keepalive, "USE peer-kpa")
09d2bf59 177
1159d4b4 178#define rxrpc_peer_traces \
47c810a7
DH
179 EM(rxrpc_peer_free, "FREE ") \
180 EM(rxrpc_peer_get_accept, "GET accept ") \
47c810a7
DH
181 EM(rxrpc_peer_get_bundle, "GET bundle ") \
182 EM(rxrpc_peer_get_client_conn, "GET cln-conn") \
5e6ef4f1 183 EM(rxrpc_peer_get_input, "GET input ") \
47c810a7
DH
184 EM(rxrpc_peer_get_input_error, "GET inpt-err") \
185 EM(rxrpc_peer_get_keepalive, "GET keepaliv") \
186 EM(rxrpc_peer_get_lookup_client, "GET look-cln") \
187 EM(rxrpc_peer_get_service_conn, "GET srv-conn") \
188 EM(rxrpc_peer_new_client, "NEW client ") \
189 EM(rxrpc_peer_new_prealloc, "NEW prealloc") \
190 EM(rxrpc_peer_put_bundle, "PUT bundle ") \
191 EM(rxrpc_peer_put_call, "PUT call ") \
192 EM(rxrpc_peer_put_conn, "PUT conn ") \
5e6ef4f1 193 EM(rxrpc_peer_put_input, "PUT input ") \
47c810a7
DH
194 EM(rxrpc_peer_put_input_error, "PUT inpt-err") \
195 E_(rxrpc_peer_put_keepalive, "PUT keepaliv")
1159d4b4 196
fa3492ab
DH
197#define rxrpc_bundle_traces \
198 EM(rxrpc_bundle_free, "FREE ") \
199 EM(rxrpc_bundle_get_client_call, "GET clt-call") \
200 EM(rxrpc_bundle_get_client_conn, "GET clt-conn") \
201 EM(rxrpc_bundle_get_service_conn, "GET svc-conn") \
1bab27af 202 EM(rxrpc_bundle_put_call, "PUT call ") \
fa3492ab
DH
203 EM(rxrpc_bundle_put_conn, "PUT conn ") \
204 EM(rxrpc_bundle_put_discard, "PUT discard ") \
205 E_(rxrpc_bundle_new, "NEW ")
206
b54a134a 207#define rxrpc_conn_traces \
7fa25105
DH
208 EM(rxrpc_conn_free, "FREE ") \
209 EM(rxrpc_conn_get_activate_call, "GET act-call") \
210 EM(rxrpc_conn_get_call_input, "GET inp-call") \
211 EM(rxrpc_conn_get_conn_input, "GET inp-conn") \
212 EM(rxrpc_conn_get_idle, "GET idle ") \
a00ce28b 213 EM(rxrpc_conn_get_poke_abort, "GET pk-abort") \
f2cce89a 214 EM(rxrpc_conn_get_poke_timer, "GET poke ") \
7fa25105
DH
215 EM(rxrpc_conn_get_service_conn, "GET svc-conn") \
216 EM(rxrpc_conn_new_client, "NEW client ") \
217 EM(rxrpc_conn_new_service, "NEW service ") \
7fa25105
DH
218 EM(rxrpc_conn_put_call, "PUT call ") \
219 EM(rxrpc_conn_put_call_input, "PUT inp-call") \
220 EM(rxrpc_conn_put_conn_input, "PUT inp-conn") \
7fa25105
DH
221 EM(rxrpc_conn_put_discard_idle, "PUT disc-idl") \
222 EM(rxrpc_conn_put_local_dead, "PUT loc-dead") \
223 EM(rxrpc_conn_put_noreuse, "PUT noreuse ") \
224 EM(rxrpc_conn_put_poke, "PUT poke ") \
3cec055c 225 EM(rxrpc_conn_put_service_reaped, "PUT svc-reap") \
7fa25105
DH
226 EM(rxrpc_conn_put_unbundle, "PUT unbundle") \
227 EM(rxrpc_conn_put_unidle, "PUT unidle ") \
f2cce89a 228 EM(rxrpc_conn_put_work, "PUT work ") \
3cec055c 229 EM(rxrpc_conn_queue_challenge, "QUE chall ") \
a00ce28b 230 EM(rxrpc_conn_queue_retry_work, "QUE retry-wk") \
3cec055c 231 EM(rxrpc_conn_queue_rx_work, "QUE rx-work ") \
7fa25105
DH
232 EM(rxrpc_conn_see_new_service_conn, "SEE new-svc ") \
233 EM(rxrpc_conn_see_reap_service, "SEE reap-svc") \
234 E_(rxrpc_conn_see_work, "SEE work ")
b54a134a
DH
235
236#define rxrpc_client_traces \
237 EM(rxrpc_client_activate_chans, "Activa") \
238 EM(rxrpc_client_alloc, "Alloc ") \
239 EM(rxrpc_client_chan_activate, "ChActv") \
240 EM(rxrpc_client_chan_disconnect, "ChDisc") \
241 EM(rxrpc_client_chan_pass, "ChPass") \
b54a134a 242 EM(rxrpc_client_cleanup, "Clean ") \
b54a134a 243 EM(rxrpc_client_discard, "Discar") \
b54a134a
DH
244 EM(rxrpc_client_exposed, "Expose") \
245 EM(rxrpc_client_replace, "Replac") \
9d35d880 246 EM(rxrpc_client_queue_new_call, "Q-Call") \
b54a134a 247 EM(rxrpc_client_to_active, "->Actv") \
245500d8 248 E_(rxrpc_client_to_idle, "->Idle")
b54a134a
DH
249
250#define rxrpc_call_traces \
5040011d 251 EM(rxrpc_call_get_io_thread, "GET iothread") \
cb0fc0c9
DH
252 EM(rxrpc_call_get_input, "GET input ") \
253 EM(rxrpc_call_get_kernel_service, "GET krnl-srv") \
254 EM(rxrpc_call_get_notify_socket, "GET notify ") \
15f661dc 255 EM(rxrpc_call_get_poke, "GET poke ") \
cb0fc0c9
DH
256 EM(rxrpc_call_get_recvmsg, "GET recvmsg ") \
257 EM(rxrpc_call_get_release_sock, "GET rel-sock") \
258 EM(rxrpc_call_get_sendmsg, "GET sendmsg ") \
cb0fc0c9
DH
259 EM(rxrpc_call_get_userid, "GET user-id ") \
260 EM(rxrpc_call_new_client, "NEW client ") \
261 EM(rxrpc_call_new_prealloc_service, "NEW prealloc") \
cb0fc0c9 262 EM(rxrpc_call_put_discard_prealloc, "PUT disc-pre") \
f3441d41 263 EM(rxrpc_call_put_discard_error, "PUT disc-err") \
5040011d 264 EM(rxrpc_call_put_io_thread, "PUT iothread") \
cb0fc0c9
DH
265 EM(rxrpc_call_put_input, "PUT input ") \
266 EM(rxrpc_call_put_kernel, "PUT kernel ") \
15f661dc 267 EM(rxrpc_call_put_poke, "PUT poke ") \
cb0fc0c9
DH
268 EM(rxrpc_call_put_recvmsg, "PUT recvmsg ") \
269 EM(rxrpc_call_put_release_sock, "PUT rls-sock") \
270 EM(rxrpc_call_put_release_sock_tba, "PUT rls-sk-a") \
cb0fc0c9 271 EM(rxrpc_call_put_sendmsg, "PUT sendmsg ") \
cb0fc0c9
DH
272 EM(rxrpc_call_put_unnotify, "PUT unnotify") \
273 EM(rxrpc_call_put_userid_exists, "PUT u-exists") \
9d35d880 274 EM(rxrpc_call_put_userid, "PUT user-id ") \
cb0fc0c9
DH
275 EM(rxrpc_call_see_accept, "SEE accept ") \
276 EM(rxrpc_call_see_activate_client, "SEE act-clnt") \
277 EM(rxrpc_call_see_connect_failed, "SEE con-fail") \
278 EM(rxrpc_call_see_connected, "SEE connect ") \
5040011d 279 EM(rxrpc_call_see_disconnected, "SEE disconn ") \
cb0fc0c9
DH
280 EM(rxrpc_call_see_distribute_error, "SEE dist-err") \
281 EM(rxrpc_call_see_input, "SEE input ") \
282 EM(rxrpc_call_see_release, "SEE release ") \
283 EM(rxrpc_call_see_userid_exists, "SEE u-exists") \
284 E_(rxrpc_call_see_zap, "SEE zap ")
b54a134a 285
a4ea4c47
DH
286#define rxrpc_txqueue_traces \
287 EM(rxrpc_txqueue_await_reply, "AWR") \
288 EM(rxrpc_txqueue_dequeue, "DEQ") \
289 EM(rxrpc_txqueue_end, "END") \
290 EM(rxrpc_txqueue_queue, "QUE") \
291 EM(rxrpc_txqueue_queue_last, "QLS") \
292 EM(rxrpc_txqueue_rotate, "ROT") \
293 EM(rxrpc_txqueue_rotate_last, "RLS") \
294 E_(rxrpc_txqueue_wait, "WAI")
b54a134a
DH
295
296#define rxrpc_receive_traces \
297 EM(rxrpc_receive_end, "END") \
298 EM(rxrpc_receive_front, "FRN") \
299 EM(rxrpc_receive_incoming, "INC") \
300 EM(rxrpc_receive_queue, "QUE") \
301 EM(rxrpc_receive_queue_last, "QLS") \
5d7edbc9
DH
302 EM(rxrpc_receive_queue_oos, "QUO") \
303 EM(rxrpc_receive_queue_oos_last, "QOL") \
304 EM(rxrpc_receive_oos, "OOS") \
305 EM(rxrpc_receive_oos_last, "OSL") \
306 EM(rxrpc_receive_rotate, "ROT") \
307 E_(rxrpc_receive_rotate_last, "RLS")
b54a134a
DH
308
309#define rxrpc_recvmsg_traces \
310 EM(rxrpc_recvmsg_cont, "CONT") \
311 EM(rxrpc_recvmsg_data_return, "DATA") \
312 EM(rxrpc_recvmsg_dequeue, "DEQU") \
313 EM(rxrpc_recvmsg_enter, "ENTR") \
314 EM(rxrpc_recvmsg_full, "FULL") \
315 EM(rxrpc_recvmsg_hole, "HOLE") \
316 EM(rxrpc_recvmsg_next, "NEXT") \
540b1c48 317 EM(rxrpc_recvmsg_requeue, "REQU") \
b54a134a
DH
318 EM(rxrpc_recvmsg_return, "RETN") \
319 EM(rxrpc_recvmsg_terminal, "TERM") \
320 EM(rxrpc_recvmsg_to_be_accepted, "TBAC") \
321 E_(rxrpc_recvmsg_wait, "WAIT")
322
323#define rxrpc_rtt_tx_traces \
4700c4d8 324 EM(rxrpc_rtt_tx_cancel, "CNCE") \
b54a134a 325 EM(rxrpc_rtt_tx_data, "DATA") \
4700c4d8 326 EM(rxrpc_rtt_tx_no_slot, "FULL") \
b54a134a
DH
327 E_(rxrpc_rtt_tx_ping, "PING")
328
329#define rxrpc_rtt_rx_traces \
4700c4d8
DH
330 EM(rxrpc_rtt_rx_cancel, "CNCL") \
331 EM(rxrpc_rtt_rx_obsolete, "OBSL") \
332 EM(rxrpc_rtt_rx_lost, "LOST") \
b54a134a
DH
333 EM(rxrpc_rtt_rx_ping_response, "PONG") \
334 E_(rxrpc_rtt_rx_requested_ack, "RACK")
335
336#define rxrpc_timer_traces \
337 EM(rxrpc_timer_begin, "Begin ") \
a158bdd3
DH
338 EM(rxrpc_timer_exp_ack, "ExpAck") \
339 EM(rxrpc_timer_exp_hard, "ExpHrd") \
340 EM(rxrpc_timer_exp_idle, "ExpIdl") \
415f44e4 341 EM(rxrpc_timer_exp_keepalive, "ExpKA ") \
bd1fdf8c 342 EM(rxrpc_timer_exp_lost_ack, "ExpLoA") \
a158bdd3
DH
343 EM(rxrpc_timer_exp_normal, "ExpNml") \
344 EM(rxrpc_timer_exp_ping, "ExpPng") \
345 EM(rxrpc_timer_exp_resend, "ExpRsn") \
b54a134a
DH
346 EM(rxrpc_timer_init_for_reply, "IniRpl") \
347 EM(rxrpc_timer_init_for_send_reply, "SndRpl") \
a158bdd3 348 EM(rxrpc_timer_restart, "Restrt") \
b54a134a 349 EM(rxrpc_timer_set_for_ack, "SetAck") \
a158bdd3
DH
350 EM(rxrpc_timer_set_for_hard, "SetHrd") \
351 EM(rxrpc_timer_set_for_idle, "SetIdl") \
415f44e4 352 EM(rxrpc_timer_set_for_keepalive, "KeepAl") \
bd1fdf8c 353 EM(rxrpc_timer_set_for_lost_ack, "SetLoA") \
a158bdd3 354 EM(rxrpc_timer_set_for_normal, "SetNml") \
b54a134a
DH
355 EM(rxrpc_timer_set_for_ping, "SetPng") \
356 EM(rxrpc_timer_set_for_resend, "SetRTx") \
a158bdd3 357 E_(rxrpc_timer_set_for_send, "SetSnd")
b54a134a
DH
358
359#define rxrpc_propose_ack_traces \
360 EM(rxrpc_propose_ack_client_tx_end, "ClTxEnd") \
361 EM(rxrpc_propose_ack_input_data, "DataIn ") \
530403d9 362 EM(rxrpc_propose_ack_input_data_hole, "DataInH") \
415f44e4 363 EM(rxrpc_propose_ack_ping_for_keepalive, "KeepAlv") \
b54a134a
DH
364 EM(rxrpc_propose_ack_ping_for_lost_ack, "LostAck") \
365 EM(rxrpc_propose_ack_ping_for_lost_reply, "LostRpl") \
84e28aa5 366 EM(rxrpc_propose_ack_ping_for_old_rtt, "OldRtt ") \
b54a134a 367 EM(rxrpc_propose_ack_ping_for_params, "Params ") \
84e28aa5 368 EM(rxrpc_propose_ack_ping_for_rtt, "Rtt ") \
b54a134a
DH
369 EM(rxrpc_propose_ack_processing_op, "ProcOp ") \
370 EM(rxrpc_propose_ack_respond_to_ack, "Rsp2Ack") \
371 EM(rxrpc_propose_ack_respond_to_ping, "Rsp2Png") \
372 EM(rxrpc_propose_ack_retry_tx, "RetryTx") \
373 EM(rxrpc_propose_ack_rotate_rx, "RxAck ") \
5e6ef4f1 374 EM(rxrpc_propose_ack_rx_idle, "RxIdle ") \
b54a134a
DH
375 E_(rxrpc_propose_ack_terminal_ack, "ClTerm ")
376
b54a134a
DH
377#define rxrpc_congest_modes \
378 EM(RXRPC_CALL_CONGEST_AVOIDANCE, "CongAvoid") \
379 EM(RXRPC_CALL_FAST_RETRANSMIT, "FastReTx ") \
380 EM(RXRPC_CALL_PACKET_LOSS, "PktLoss ") \
381 E_(RXRPC_CALL_SLOW_START, "SlowStart")
382
383#define rxrpc_congest_changes \
384 EM(rxrpc_cong_begin_retransmission, " Retrans") \
385 EM(rxrpc_cong_cleared_nacks, " Cleared") \
386 EM(rxrpc_cong_new_low_nack, " NewLowN") \
aadf9dce 387 EM(rxrpc_cong_no_change, " -") \
b54a134a 388 EM(rxrpc_cong_progress, " Progres") \
1fc4fa2a 389 EM(rxrpc_cong_idle_reset, " IdleRes") \
b54a134a
DH
390 EM(rxrpc_cong_retransmit_again, " ReTxAgn") \
391 EM(rxrpc_cong_rtt_window_end, " RttWinE") \
392 E_(rxrpc_cong_saw_nack, " SawNack")
393
394#define rxrpc_pkts \
395 EM(0, "?00") \
396 EM(RXRPC_PACKET_TYPE_DATA, "DATA") \
397 EM(RXRPC_PACKET_TYPE_ACK, "ACK") \
398 EM(RXRPC_PACKET_TYPE_BUSY, "BUSY") \
399 EM(RXRPC_PACKET_TYPE_ABORT, "ABORT") \
400 EM(RXRPC_PACKET_TYPE_ACKALL, "ACKALL") \
401 EM(RXRPC_PACKET_TYPE_CHALLENGE, "CHALL") \
402 EM(RXRPC_PACKET_TYPE_RESPONSE, "RESP") \
403 EM(RXRPC_PACKET_TYPE_DEBUG, "DEBUG") \
404 EM(9, "?09") \
405 EM(10, "?10") \
406 EM(11, "?11") \
407 EM(12, "?12") \
408 EM(RXRPC_PACKET_TYPE_VERSION, "VERSION") \
409 EM(14, "?14") \
410 E_(15, "?15")
411
412#define rxrpc_ack_names \
413 EM(0, "-0-") \
414 EM(RXRPC_ACK_REQUESTED, "REQ") \
415 EM(RXRPC_ACK_DUPLICATE, "DUP") \
416 EM(RXRPC_ACK_OUT_OF_SEQUENCE, "OOS") \
417 EM(RXRPC_ACK_EXCEEDS_WINDOW, "WIN") \
418 EM(RXRPC_ACK_NOSPACE, "MEM") \
419 EM(RXRPC_ACK_PING, "PNG") \
420 EM(RXRPC_ACK_PING_RESPONSE, "PNR") \
421 EM(RXRPC_ACK_DELAY, "DLY") \
422 EM(RXRPC_ACK_IDLE, "IDL") \
423 E_(RXRPC_ACK__INVALID, "-?-")
424
f21e9348
DH
425#define rxrpc_sack_traces \
426 EM(rxrpc_sack_advance, "ADV") \
427 EM(rxrpc_sack_fill, "FIL") \
428 EM(rxrpc_sack_nack, "NAK") \
429 EM(rxrpc_sack_none, "---") \
430 E_(rxrpc_sack_oos, "OOS")
431
1bae5d22
DH
432#define rxrpc_completions \
433 EM(RXRPC_CALL_SUCCEEDED, "Succeeded") \
434 EM(RXRPC_CALL_REMOTELY_ABORTED, "RemoteAbort") \
435 EM(RXRPC_CALL_LOCALLY_ABORTED, "LocalAbort") \
436 EM(RXRPC_CALL_LOCAL_ERROR, "LocalError") \
437 E_(RXRPC_CALL_NETWORK_ERROR, "NetError")
438
4764c0da
DH
439#define rxrpc_tx_points \
440 EM(rxrpc_tx_point_call_abort, "CallAbort") \
441 EM(rxrpc_tx_point_call_ack, "CallAck") \
442 EM(rxrpc_tx_point_call_data_frag, "CallDataFrag") \
443 EM(rxrpc_tx_point_call_data_nofrag, "CallDataNofrag") \
444 EM(rxrpc_tx_point_call_final_resend, "CallFinalResend") \
445 EM(rxrpc_tx_point_conn_abort, "ConnAbort") \
446 EM(rxrpc_tx_point_reject, "Reject") \
447 EM(rxrpc_tx_point_rxkad_challenge, "RxkadChall") \
448 EM(rxrpc_tx_point_rxkad_response, "RxkadResp") \
449 EM(rxrpc_tx_point_version_keepalive, "VerKeepalive") \
450 E_(rxrpc_tx_point_version_reply, "VerReply")
6b47fe1d 451
4d843be5
DH
452#define rxrpc_req_ack_traces \
453 EM(rxrpc_reqack_ack_lost, "ACK-LOST ") \
454 EM(rxrpc_reqack_already_on, "ALREADY-ON") \
455 EM(rxrpc_reqack_more_rtt, "MORE-RTT ") \
456 EM(rxrpc_reqack_no_srv_last, "NO-SRVLAST") \
457 EM(rxrpc_reqack_old_rtt, "OLD-RTT ") \
458 EM(rxrpc_reqack_retrans, "RETRANS ") \
459 EM(rxrpc_reqack_slow_start, "SLOW-START") \
460 E_(rxrpc_reqack_small_txwin, "SMALL-TXWN")
f7fa5242 461/* ---- Must update size of stat_why_req_ack[] if more are added! */
4d843be5 462
02a19356
DH
463#define rxrpc_txbuf_traces \
464 EM(rxrpc_txbuf_alloc_ack, "ALLOC ACK ") \
465 EM(rxrpc_txbuf_alloc_data, "ALLOC DATA ") \
466 EM(rxrpc_txbuf_free, "FREE ") \
a4ea4c47 467 EM(rxrpc_txbuf_get_buffer, "GET BUFFER ") \
02a19356
DH
468 EM(rxrpc_txbuf_get_trans, "GET TRANS ") \
469 EM(rxrpc_txbuf_get_retrans, "GET RETRANS") \
72f0c6fb 470 EM(rxrpc_txbuf_put_ack_tx, "PUT ACK TX ") \
02a19356 471 EM(rxrpc_txbuf_put_cleaned, "PUT CLEANED") \
72f0c6fb 472 EM(rxrpc_txbuf_put_nomem, "PUT NOMEM ") \
02a19356
DH
473 EM(rxrpc_txbuf_put_rotated, "PUT ROTATED") \
474 EM(rxrpc_txbuf_put_send_aborted, "PUT SEND-X ") \
a4ea4c47 475 EM(rxrpc_txbuf_put_trans, "PUT TRANS ") \
3feda9d6 476 EM(rxrpc_txbuf_see_out_of_step, "OUT-OF-STEP") \
02a19356
DH
477 EM(rxrpc_txbuf_see_send_more, "SEE SEND+ ") \
478 E_(rxrpc_txbuf_see_unacked, "SEE UNACKED")
479
dc9fd093
DH
480/*
481 * Generate enums for tracing information.
482 */
483#ifndef __NETFS_DECLARE_TRACE_ENUMS_ONCE_ONLY
484#define __NETFS_DECLARE_TRACE_ENUMS_ONCE_ONLY
485
486#undef EM
487#undef E_
488#define EM(a, b) a,
489#define E_(a, b) a
490
57af281e 491enum rxrpc_abort_reason { rxrpc_abort_reasons } __mode(byte);
fa3492ab 492enum rxrpc_bundle_trace { rxrpc_bundle_traces } __mode(byte);
15f661dc 493enum rxrpc_call_poke_trace { rxrpc_call_poke_traces } __mode(byte);
dc9fd093
DH
494enum rxrpc_call_trace { rxrpc_call_traces } __mode(byte);
495enum rxrpc_client_trace { rxrpc_client_traces } __mode(byte);
496enum rxrpc_congest_change { rxrpc_congest_changes } __mode(byte);
497enum rxrpc_conn_trace { rxrpc_conn_traces } __mode(byte);
498enum rxrpc_local_trace { rxrpc_local_traces } __mode(byte);
499enum rxrpc_peer_trace { rxrpc_peer_traces } __mode(byte);
500enum rxrpc_propose_ack_outcome { rxrpc_propose_ack_outcomes } __mode(byte);
501enum rxrpc_propose_ack_trace { rxrpc_propose_ack_traces } __mode(byte);
502enum rxrpc_receive_trace { rxrpc_receive_traces } __mode(byte);
503enum rxrpc_recvmsg_trace { rxrpc_recvmsg_traces } __mode(byte);
4d843be5 504enum rxrpc_req_ack_trace { rxrpc_req_ack_traces } __mode(byte);
dc9fd093
DH
505enum rxrpc_rtt_rx_trace { rxrpc_rtt_rx_traces } __mode(byte);
506enum rxrpc_rtt_tx_trace { rxrpc_rtt_tx_traces } __mode(byte);
f21e9348 507enum rxrpc_sack_trace { rxrpc_sack_traces } __mode(byte);
dc9fd093
DH
508enum rxrpc_skb_trace { rxrpc_skb_traces } __mode(byte);
509enum rxrpc_timer_trace { rxrpc_timer_traces } __mode(byte);
dc9fd093 510enum rxrpc_tx_point { rxrpc_tx_points } __mode(byte);
02a19356 511enum rxrpc_txbuf_trace { rxrpc_txbuf_traces } __mode(byte);
a4ea4c47 512enum rxrpc_txqueue_trace { rxrpc_txqueue_traces } __mode(byte);
dc9fd093
DH
513
514#endif /* end __RXRPC_DECLARE_TRACE_ENUMS_ONCE_ONLY */
515
b54a134a
DH
516/*
517 * Export enum symbols via userspace.
518 */
519#undef EM
520#undef E_
57af281e
DH
521
522#ifndef RXRPC_TRACE_ONLY_DEFINE_ENUMS
523
b54a134a
DH
524#define EM(a, b) TRACE_DEFINE_ENUM(a);
525#define E_(a, b) TRACE_DEFINE_ENUM(a);
526
57af281e 527rxrpc_abort_reasons;
fa3492ab 528rxrpc_bundle_traces;
15f661dc 529rxrpc_call_poke_traces;
b54a134a 530rxrpc_call_traces;
dc9fd093
DH
531rxrpc_client_traces;
532rxrpc_congest_changes;
533rxrpc_congest_modes;
534rxrpc_conn_traces;
535rxrpc_local_traces;
dc9fd093 536rxrpc_propose_ack_traces;
b54a134a
DH
537rxrpc_receive_traces;
538rxrpc_recvmsg_traces;
4d843be5 539rxrpc_req_ack_traces;
b54a134a 540rxrpc_rtt_rx_traces;
dc9fd093 541rxrpc_rtt_tx_traces;
f21e9348 542rxrpc_sack_traces;
dc9fd093 543rxrpc_skb_traces;
b54a134a 544rxrpc_timer_traces;
4764c0da 545rxrpc_tx_points;
02a19356 546rxrpc_txbuf_traces;
a4ea4c47 547rxrpc_txqueue_traces;
b54a134a
DH
548
549/*
550 * Now redefine the EM() and E_() macros to map the enums to the strings that
551 * will be printed in the output.
552 */
553#undef EM
554#undef E_
555#define EM(a, b) { a, b },
556#define E_(a, b) { a, b }
557
09d2bf59 558TRACE_EVENT(rxrpc_local,
06d9532f 559 TP_PROTO(unsigned int local_debug_id, enum rxrpc_local_trace op,
0fde882f 560 int ref, int usage),
09d2bf59 561
0fde882f 562 TP_ARGS(local_debug_id, op, ref, usage),
09d2bf59
DH
563
564 TP_STRUCT__entry(
371e68ba
DH
565 __field(unsigned int, local)
566 __field(int, op)
567 __field(int, ref)
568 __field(int, usage)
09d2bf59
DH
569 ),
570
571 TP_fast_assign(
06d9532f 572 __entry->local = local_debug_id;
09d2bf59 573 __entry->op = op;
0fde882f 574 __entry->ref = ref;
09d2bf59 575 __entry->usage = usage;
09d2bf59
DH
576 ),
577
0fde882f 578 TP_printk("L=%08x %s r=%d u=%d",
09d2bf59
DH
579 __entry->local,
580 __print_symbolic(__entry->op, rxrpc_local_traces),
0fde882f
DH
581 __entry->ref,
582 __entry->usage)
09d2bf59
DH
583 );
584
1159d4b4 585TRACE_EVENT(rxrpc_peer,
47c810a7 586 TP_PROTO(unsigned int peer_debug_id, int ref, enum rxrpc_peer_trace why),
1159d4b4 587
47c810a7 588 TP_ARGS(peer_debug_id, ref, why),
1159d4b4
DH
589
590 TP_STRUCT__entry(
371e68ba
DH
591 __field(unsigned int, peer)
592 __field(int, ref)
593 __field(enum rxrpc_peer_trace, why)
1159d4b4
DH
594 ),
595
596 TP_fast_assign(
55f6c98e 597 __entry->peer = peer_debug_id;
47c810a7
DH
598 __entry->ref = ref;
599 __entry->why = why;
1159d4b4
DH
600 ),
601
47c810a7 602 TP_printk("P=%08x %s r=%d",
1159d4b4 603 __entry->peer,
47c810a7
DH
604 __print_symbolic(__entry->why, rxrpc_peer_traces),
605 __entry->ref)
1159d4b4
DH
606 );
607
fa3492ab
DH
608TRACE_EVENT(rxrpc_bundle,
609 TP_PROTO(unsigned int bundle_debug_id, int ref, enum rxrpc_bundle_trace why),
610
611 TP_ARGS(bundle_debug_id, ref, why),
612
613 TP_STRUCT__entry(
371e68ba
DH
614 __field(unsigned int, bundle)
615 __field(int, ref)
616 __field(int, why)
fa3492ab
DH
617 ),
618
619 TP_fast_assign(
620 __entry->bundle = bundle_debug_id;
621 __entry->ref = ref;
622 __entry->why = why;
623 ),
624
625 TP_printk("CB=%08x %s r=%d",
626 __entry->bundle,
627 __print_symbolic(__entry->why, rxrpc_bundle_traces),
628 __entry->ref)
629 );
630
363deeab 631TRACE_EVENT(rxrpc_conn,
7fa25105 632 TP_PROTO(unsigned int conn_debug_id, int ref, enum rxrpc_conn_trace why),
363deeab 633
7fa25105 634 TP_ARGS(conn_debug_id, ref, why),
363deeab
DH
635
636 TP_STRUCT__entry(
371e68ba
DH
637 __field(unsigned int, conn)
638 __field(int, ref)
639 __field(int, why)
363deeab
DH
640 ),
641
642 TP_fast_assign(
4c1295dc 643 __entry->conn = conn_debug_id;
7fa25105
DH
644 __entry->ref = ref;
645 __entry->why = why;
363deeab
DH
646 ),
647
7fa25105 648 TP_printk("C=%08x %s r=%d",
363deeab 649 __entry->conn,
7fa25105
DH
650 __print_symbolic(__entry->why, rxrpc_conn_traces),
651 __entry->ref)
363deeab
DH
652 );
653
654TRACE_EVENT(rxrpc_client,
655 TP_PROTO(struct rxrpc_connection *conn, int channel,
656 enum rxrpc_client_trace op),
657
658 TP_ARGS(conn, channel, op),
659
660 TP_STRUCT__entry(
371e68ba
DH
661 __field(unsigned int, conn)
662 __field(u32, cid)
663 __field(int, channel)
664 __field(int, usage)
665 __field(enum rxrpc_client_trace, op)
363deeab
DH
666 ),
667
668 TP_fast_assign(
245500d8 669 __entry->conn = conn ? conn->debug_id : 0;
363deeab 670 __entry->channel = channel;
a0575429 671 __entry->usage = conn ? refcount_read(&conn->ref) : -2;
363deeab 672 __entry->op = op;
96a9c425 673 __entry->cid = conn ? conn->proto.cid : 0;
363deeab
DH
674 ),
675
245500d8 676 TP_printk("C=%08x h=%2d %s i=%08x u=%d",
363deeab
DH
677 __entry->conn,
678 __entry->channel,
b54a134a 679 __print_symbolic(__entry->op, rxrpc_client_traces),
363deeab
DH
680 __entry->cid,
681 __entry->usage)
682 );
683
e34d4234 684TRACE_EVENT(rxrpc_call,
cb0fc0c9
DH
685 TP_PROTO(unsigned int call_debug_id, int ref, unsigned long aux,
686 enum rxrpc_call_trace why),
e34d4234 687
cb0fc0c9 688 TP_ARGS(call_debug_id, ref, aux, why),
e34d4234
DH
689
690 TP_STRUCT__entry(
828bebc8
DH
691 __field(unsigned int, call)
692 __field(int, ref)
693 __field(int, why)
694 __field(unsigned long, aux)
e34d4234
DH
695 ),
696
697 TP_fast_assign(
48c9e0ec 698 __entry->call = call_debug_id;
cb0fc0c9
DH
699 __entry->ref = ref;
700 __entry->why = why;
e34d4234
DH
701 __entry->aux = aux;
702 ),
703
cb0fc0c9 704 TP_printk("c=%08x %s r=%d a=%lx",
e34d4234 705 __entry->call,
cb0fc0c9
DH
706 __print_symbolic(__entry->why, rxrpc_call_traces),
707 __entry->ref,
e34d4234
DH
708 __entry->aux)
709 );
710
df844fd4 711TRACE_EVENT(rxrpc_skb,
9a36a6bc
DH
712 TP_PROTO(struct sk_buff *skb, int usage, int mod_count,
713 enum rxrpc_skb_trace why),
df844fd4 714
9a36a6bc 715 TP_ARGS(skb, usage, mod_count, why),
df844fd4
DH
716
717 TP_STRUCT__entry(
371e68ba
DH
718 __field(struct sk_buff *, skb)
719 __field(int, usage)
720 __field(int, mod_count)
721 __field(enum rxrpc_skb_trace, why)
df844fd4
DH
722 ),
723
724 TP_fast_assign(
725 __entry->skb = skb;
df844fd4
DH
726 __entry->usage = usage;
727 __entry->mod_count = mod_count;
9a36a6bc 728 __entry->why = why;
df844fd4
DH
729 ),
730
9a36a6bc 731 TP_printk("s=%p Rx %s u=%d m=%d",
df844fd4 732 __entry->skb,
9a36a6bc 733 __print_symbolic(__entry->why, rxrpc_skb_traces),
df844fd4 734 __entry->usage,
9a36a6bc 735 __entry->mod_count)
df844fd4
DH
736 );
737
49e19ec7
DH
738TRACE_EVENT(rxrpc_rx_packet,
739 TP_PROTO(struct rxrpc_skb_priv *sp),
740
741 TP_ARGS(sp),
742
743 TP_STRUCT__entry(
371e68ba 744 __field_struct(struct rxrpc_host_header, hdr)
49e19ec7
DH
745 ),
746
747 TP_fast_assign(
748 memcpy(&__entry->hdr, &sp->hdr, sizeof(__entry->hdr));
749 ),
750
a3868bfc 751 TP_printk("%08x:%08x:%08x:%04x %08x %08x %02x %02x %s",
49e19ec7
DH
752 __entry->hdr.epoch, __entry->hdr.cid,
753 __entry->hdr.callNumber, __entry->hdr.serviceId,
754 __entry->hdr.serial, __entry->hdr.seq,
83836eb4
DH
755 __entry->hdr.securityIndex, __entry->hdr.flags,
756 __print_symbolic(__entry->hdr.type, rxrpc_pkts))
49e19ec7
DH
757 );
758
759TRACE_EVENT(rxrpc_rx_done,
760 TP_PROTO(int result, int abort_code),
761
762 TP_ARGS(result, abort_code),
763
764 TP_STRUCT__entry(
828bebc8
DH
765 __field(int, result)
766 __field(int, abort_code)
49e19ec7
DH
767 ),
768
769 TP_fast_assign(
770 __entry->result = result;
771 __entry->abort_code = abort_code;
772 ),
773
774 TP_printk("r=%d a=%d", __entry->result, __entry->abort_code)
775 );
776
5a42976d 777TRACE_EVENT(rxrpc_abort,
57af281e
DH
778 TP_PROTO(unsigned int call_nr, enum rxrpc_abort_reason why,
779 u32 cid, u32 call_id, rxrpc_seq_t seq, int abort_code, int error),
5a42976d 780
a25e21f0 781 TP_ARGS(call_nr, why, cid, call_id, seq, abort_code, error),
5a42976d
DH
782
783 TP_STRUCT__entry(
371e68ba
DH
784 __field(unsigned int, call_nr)
785 __field(enum rxrpc_abort_reason, why)
786 __field(u32, cid)
787 __field(u32, call_id)
788 __field(rxrpc_seq_t, seq)
789 __field(int, abort_code)
790 __field(int, error)
5a42976d
DH
791 ),
792
793 TP_fast_assign(
a25e21f0 794 __entry->call_nr = call_nr;
57af281e 795 __entry->why = why;
5a42976d
DH
796 __entry->cid = cid;
797 __entry->call_id = call_id;
798 __entry->abort_code = abort_code;
799 __entry->error = error;
800 __entry->seq = seq;
801 ),
802
a25e21f0
DH
803 TP_printk("c=%08x %08x:%08x s=%u a=%d e=%d %s",
804 __entry->call_nr,
5a42976d 805 __entry->cid, __entry->call_id, __entry->seq,
57af281e
DH
806 __entry->abort_code, __entry->error,
807 __print_symbolic(__entry->why, rxrpc_abort_reasons))
5a42976d
DH
808 );
809
1bae5d22
DH
810TRACE_EVENT(rxrpc_call_complete,
811 TP_PROTO(struct rxrpc_call *call),
812
813 TP_ARGS(call),
814
815 TP_STRUCT__entry(
371e68ba
DH
816 __field(unsigned int, call)
817 __field(enum rxrpc_call_completion, compl)
818 __field(int, error)
819 __field(u32, abort_code)
1bae5d22
DH
820 ),
821
822 TP_fast_assign(
823 __entry->call = call->debug_id;
824 __entry->compl = call->completion;
825 __entry->error = call->error;
826 __entry->abort_code = call->abort_code;
827 ),
828
829 TP_printk("c=%08x %s r=%d ac=%d",
830 __entry->call,
831 __print_symbolic(__entry->compl, rxrpc_completions),
832 __entry->error,
833 __entry->abort_code)
834 );
835
a4ea4c47
DH
836TRACE_EVENT(rxrpc_txqueue,
837 TP_PROTO(struct rxrpc_call *call, enum rxrpc_txqueue_trace why),
a124fe3e
DH
838
839 TP_ARGS(call, why),
840
841 TP_STRUCT__entry(
371e68ba
DH
842 __field(unsigned int, call)
843 __field(enum rxrpc_txqueue_trace, why)
844 __field(rxrpc_seq_t, acks_hard_ack)
845 __field(rxrpc_seq_t, tx_bottom)
846 __field(rxrpc_seq_t, tx_top)
847 __field(rxrpc_seq_t, tx_prepared)
848 __field(int, tx_winsize)
a124fe3e
DH
849 ),
850
851 TP_fast_assign(
a25e21f0 852 __entry->call = call->debug_id;
a124fe3e 853 __entry->why = why;
a4ea4c47
DH
854 __entry->acks_hard_ack = call->acks_hard_ack;
855 __entry->tx_bottom = call->tx_bottom;
a124fe3e 856 __entry->tx_top = call->tx_top;
cf37b598 857 __entry->tx_prepared = call->tx_prepared;
b1d9f7fd 858 __entry->tx_winsize = call->tx_winsize;
a124fe3e
DH
859 ),
860
cf37b598 861 TP_printk("c=%08x %s f=%08x h=%08x n=%u/%u/%u/%u",
a124fe3e 862 __entry->call,
a4ea4c47
DH
863 __print_symbolic(__entry->why, rxrpc_txqueue_traces),
864 __entry->tx_bottom,
865 __entry->acks_hard_ack,
866 __entry->tx_top - __entry->tx_bottom,
867 __entry->tx_top - __entry->acks_hard_ack,
cf37b598 868 __entry->tx_prepared - __entry->tx_bottom,
b1d9f7fd
DH
869 __entry->tx_winsize)
870 );
871
872TRACE_EVENT(rxrpc_rx_data,
4764c0da 873 TP_PROTO(unsigned int call, rxrpc_seq_t seq,
d4d02d8b 874 rxrpc_serial_t serial, u8 flags),
b1d9f7fd 875
d4d02d8b 876 TP_ARGS(call, seq, serial, flags),
b1d9f7fd
DH
877
878 TP_STRUCT__entry(
828bebc8
DH
879 __field(unsigned int, call)
880 __field(rxrpc_seq_t, seq)
881 __field(rxrpc_serial_t, serial)
882 __field(u8, flags)
b1d9f7fd
DH
883 ),
884
885 TP_fast_assign(
4764c0da 886 __entry->call = call;
b1d9f7fd
DH
887 __entry->seq = seq;
888 __entry->serial = serial;
889 __entry->flags = flags;
b1d9f7fd
DH
890 ),
891
d4d02d8b 892 TP_printk("c=%08x DATA %08x q=%08x fl=%02x",
b1d9f7fd
DH
893 __entry->call,
894 __entry->serial,
895 __entry->seq,
d4d02d8b 896 __entry->flags)
a124fe3e
DH
897 );
898
ec71eb9a 899TRACE_EVENT(rxrpc_rx_ack,
b1d9f7fd
DH
900 TP_PROTO(struct rxrpc_call *call,
901 rxrpc_serial_t serial, rxrpc_serial_t ack_serial,
902 rxrpc_seq_t first, rxrpc_seq_t prev, u8 reason, u8 n_acks),
ec71eb9a 903
b1d9f7fd 904 TP_ARGS(call, serial, ack_serial, first, prev, reason, n_acks),
ec71eb9a
DH
905
906 TP_STRUCT__entry(
828bebc8
DH
907 __field(unsigned int, call)
908 __field(rxrpc_serial_t, serial)
909 __field(rxrpc_serial_t, ack_serial)
910 __field(rxrpc_seq_t, first)
911 __field(rxrpc_seq_t, prev)
912 __field(u8, reason)
913 __field(u8, n_acks)
ec71eb9a
DH
914 ),
915
916 TP_fast_assign(
a25e21f0 917 __entry->call = call->debug_id;
b1d9f7fd
DH
918 __entry->serial = serial;
919 __entry->ack_serial = ack_serial;
ec71eb9a 920 __entry->first = first;
b1d9f7fd 921 __entry->prev = prev;
ec71eb9a
DH
922 __entry->reason = reason;
923 __entry->n_acks = n_acks;
924 ),
925
a25e21f0 926 TP_printk("c=%08x %08x %s r=%08x f=%08x p=%08x n=%u",
ec71eb9a 927 __entry->call,
b1d9f7fd 928 __entry->serial,
b54a134a 929 __print_symbolic(__entry->reason, rxrpc_ack_names),
b1d9f7fd 930 __entry->ack_serial,
ec71eb9a 931 __entry->first,
b1d9f7fd 932 __entry->prev,
ec71eb9a
DH
933 __entry->n_acks)
934 );
935
005ede28
DH
936TRACE_EVENT(rxrpc_rx_abort,
937 TP_PROTO(struct rxrpc_call *call, rxrpc_serial_t serial,
938 u32 abort_code),
939
940 TP_ARGS(call, serial, abort_code),
941
942 TP_STRUCT__entry(
828bebc8
DH
943 __field(unsigned int, call)
944 __field(rxrpc_serial_t, serial)
945 __field(u32, abort_code)
005ede28
DH
946 ),
947
948 TP_fast_assign(
a25e21f0 949 __entry->call = call->debug_id;
005ede28
DH
950 __entry->serial = serial;
951 __entry->abort_code = abort_code;
952 ),
953
a25e21f0 954 TP_printk("c=%08x ABORT %08x ac=%d",
005ede28
DH
955 __entry->call,
956 __entry->serial,
957 __entry->abort_code)
958 );
959
2ebdb26e
DH
960TRACE_EVENT(rxrpc_rx_challenge,
961 TP_PROTO(struct rxrpc_connection *conn, rxrpc_serial_t serial,
962 u32 version, u32 nonce, u32 min_level),
963
964 TP_ARGS(conn, serial, version, nonce, min_level),
965
966 TP_STRUCT__entry(
828bebc8
DH
967 __field(unsigned int, conn)
968 __field(rxrpc_serial_t, serial)
969 __field(u32, version)
970 __field(u32, nonce)
971 __field(u32, min_level)
2ebdb26e
DH
972 ),
973
974 TP_fast_assign(
975 __entry->conn = conn->debug_id;
976 __entry->serial = serial;
977 __entry->version = version;
978 __entry->nonce = nonce;
979 __entry->min_level = min_level;
980 ),
981
982 TP_printk("C=%08x CHALLENGE %08x v=%x n=%x ml=%x",
983 __entry->conn,
984 __entry->serial,
985 __entry->version,
986 __entry->nonce,
987 __entry->min_level)
988 );
989
990TRACE_EVENT(rxrpc_rx_response,
991 TP_PROTO(struct rxrpc_connection *conn, rxrpc_serial_t serial,
992 u32 version, u32 kvno, u32 ticket_len),
993
994 TP_ARGS(conn, serial, version, kvno, ticket_len),
995
996 TP_STRUCT__entry(
828bebc8
DH
997 __field(unsigned int, conn)
998 __field(rxrpc_serial_t, serial)
999 __field(u32, version)
1000 __field(u32, kvno)
1001 __field(u32, ticket_len)
2ebdb26e
DH
1002 ),
1003
1004 TP_fast_assign(
1005 __entry->conn = conn->debug_id;
1006 __entry->serial = serial;
1007 __entry->version = version;
1008 __entry->kvno = kvno;
1009 __entry->ticket_len = ticket_len;
1010 ),
1011
1012 TP_printk("C=%08x RESPONSE %08x v=%x kvno=%x tl=%x",
1013 __entry->conn,
1014 __entry->serial,
1015 __entry->version,
1016 __entry->kvno,
1017 __entry->ticket_len)
1018 );
1019
740586d2
DH
1020TRACE_EVENT(rxrpc_rx_rwind_change,
1021 TP_PROTO(struct rxrpc_call *call, rxrpc_serial_t serial,
1022 u32 rwind, bool wake),
1023
1024 TP_ARGS(call, serial, rwind, wake),
1025
1026 TP_STRUCT__entry(
828bebc8
DH
1027 __field(unsigned int, call)
1028 __field(rxrpc_serial_t, serial)
1029 __field(u32, rwind)
1030 __field(bool, wake)
740586d2
DH
1031 ),
1032
1033 TP_fast_assign(
a25e21f0 1034 __entry->call = call->debug_id;
740586d2
DH
1035 __entry->serial = serial;
1036 __entry->rwind = rwind;
1037 __entry->wake = wake;
1038 ),
1039
a25e21f0 1040 TP_printk("c=%08x %08x rw=%u%s",
740586d2
DH
1041 __entry->call,
1042 __entry->serial,
1043 __entry->rwind,
1044 __entry->wake ? " wake" : "")
1045 );
1046
4764c0da
DH
1047TRACE_EVENT(rxrpc_tx_packet,
1048 TP_PROTO(unsigned int call_id, struct rxrpc_wire_header *whdr,
1049 enum rxrpc_tx_point where),
1050
1051 TP_ARGS(call_id, whdr, where),
1052
1053 TP_STRUCT__entry(
371e68ba
DH
1054 __field(unsigned int, call)
1055 __field(enum rxrpc_tx_point, where)
1056 __field_struct(struct rxrpc_wire_header, whdr)
4764c0da
DH
1057 ),
1058
1059 TP_fast_assign(
1060 __entry->call = call_id;
1061 memcpy(&__entry->whdr, whdr, sizeof(__entry->whdr));
4e2abd3c 1062 __entry->where = where;
4764c0da
DH
1063 ),
1064
1065 TP_printk("c=%08x %08x:%08x:%08x:%04x %08x %08x %02x %02x %s %s",
1066 __entry->call,
1067 ntohl(__entry->whdr.epoch),
1068 ntohl(__entry->whdr.cid),
1069 ntohl(__entry->whdr.callNumber),
1070 ntohs(__entry->whdr.serviceId),
1071 ntohl(__entry->whdr.serial),
1072 ntohl(__entry->whdr.seq),
1073 __entry->whdr.type, __entry->whdr.flags,
1074 __entry->whdr.type <= 15 ?
1075 __print_symbolic(__entry->whdr.type, rxrpc_pkts) : "?UNK",
1076 __print_symbolic(__entry->where, rxrpc_tx_points))
1077 );
1078
be832aec
DH
1079TRACE_EVENT(rxrpc_tx_data,
1080 TP_PROTO(struct rxrpc_call *call, rxrpc_seq_t seq,
a1767077 1081 rxrpc_serial_t serial, u8 flags, bool retrans, bool lose),
be832aec 1082
a1767077 1083 TP_ARGS(call, seq, serial, flags, retrans, lose),
be832aec
DH
1084
1085 TP_STRUCT__entry(
828bebc8
DH
1086 __field(unsigned int, call)
1087 __field(rxrpc_seq_t, seq)
1088 __field(rxrpc_serial_t, serial)
1089 __field(u32, cid)
1090 __field(u32, call_id)
1091 __field(u8, flags)
1092 __field(bool, retrans)
1093 __field(bool, lose)
be832aec
DH
1094 ),
1095
1096 TP_fast_assign(
a25e21f0 1097 __entry->call = call->debug_id;
4764c0da
DH
1098 __entry->cid = call->cid;
1099 __entry->call_id = call->call_id;
be832aec
DH
1100 __entry->seq = seq;
1101 __entry->serial = serial;
1102 __entry->flags = flags;
a1767077 1103 __entry->retrans = retrans;
be832aec
DH
1104 __entry->lose = lose;
1105 ),
1106
4764c0da 1107 TP_printk("c=%08x DATA %08x:%08x %08x q=%08x fl=%02x%s%s",
be832aec 1108 __entry->call,
4764c0da
DH
1109 __entry->cid,
1110 __entry->call_id,
be832aec
DH
1111 __entry->serial,
1112 __entry->seq,
1113 __entry->flags,
265a44bb 1114 __entry->retrans ? " *RETRANS*" : "",
be832aec
DH
1115 __entry->lose ? " *LOSE*" : "")
1116 );
1117
f3639df2 1118TRACE_EVENT(rxrpc_tx_ack,
4764c0da 1119 TP_PROTO(unsigned int call, rxrpc_serial_t serial,
be832aec
DH
1120 rxrpc_seq_t ack_first, rxrpc_serial_t ack_serial,
1121 u8 reason, u8 n_acks),
f3639df2 1122
be832aec 1123 TP_ARGS(call, serial, ack_first, ack_serial, reason, n_acks),
f3639df2
DH
1124
1125 TP_STRUCT__entry(
828bebc8
DH
1126 __field(unsigned int, call)
1127 __field(rxrpc_serial_t, serial)
1128 __field(rxrpc_seq_t, ack_first)
1129 __field(rxrpc_serial_t, ack_serial)
1130 __field(u8, reason)
1131 __field(u8, n_acks)
f3639df2
DH
1132 ),
1133
1134 TP_fast_assign(
4764c0da 1135 __entry->call = call;
f3639df2 1136 __entry->serial = serial;
be832aec
DH
1137 __entry->ack_first = ack_first;
1138 __entry->ack_serial = ack_serial;
f3639df2
DH
1139 __entry->reason = reason;
1140 __entry->n_acks = n_acks;
1141 ),
1142
a25e21f0 1143 TP_printk(" c=%08x ACK %08x %s f=%08x r=%08x n=%u",
f3639df2 1144 __entry->call,
f3639df2 1145 __entry->serial,
b54a134a 1146 __print_symbolic(__entry->reason, rxrpc_ack_names),
be832aec
DH
1147 __entry->ack_first,
1148 __entry->ack_serial,
f3639df2
DH
1149 __entry->n_acks)
1150 );
1151
58dc63c9
DH
1152TRACE_EVENT(rxrpc_receive,
1153 TP_PROTO(struct rxrpc_call *call, enum rxrpc_receive_trace why,
1154 rxrpc_serial_t serial, rxrpc_seq_t seq),
1155
1156 TP_ARGS(call, why, serial, seq),
1157
1158 TP_STRUCT__entry(
371e68ba
DH
1159 __field(unsigned int, call)
1160 __field(enum rxrpc_receive_trace, why)
1161 __field(rxrpc_serial_t, serial)
1162 __field(rxrpc_seq_t, seq)
5bbf9533
DH
1163 __field(rxrpc_seq_t, window)
1164 __field(rxrpc_seq_t, wtop)
58dc63c9
DH
1165 ),
1166
1167 TP_fast_assign(
a25e21f0 1168 __entry->call = call->debug_id;
58dc63c9
DH
1169 __entry->why = why;
1170 __entry->serial = serial;
1171 __entry->seq = seq;
5bbf9533
DH
1172 __entry->window = call->ackr_window;
1173 __entry->wtop = call->ackr_wtop;
58dc63c9
DH
1174 ),
1175
a25e21f0 1176 TP_printk("c=%08x %s r=%08x q=%08x w=%08x-%08x",
58dc63c9 1177 __entry->call,
b54a134a 1178 __print_symbolic(__entry->why, rxrpc_receive_traces),
58dc63c9
DH
1179 __entry->serial,
1180 __entry->seq,
5bbf9533
DH
1181 __entry->window,
1182 __entry->wtop)
58dc63c9
DH
1183 );
1184
84997905 1185TRACE_EVENT(rxrpc_recvmsg,
0e50d999 1186 TP_PROTO(unsigned int call_debug_id, enum rxrpc_recvmsg_trace why,
faf92e8d
DH
1187 int ret),
1188
0e50d999 1189 TP_ARGS(call_debug_id, why, ret),
faf92e8d
DH
1190
1191 TP_STRUCT__entry(
371e68ba
DH
1192 __field(unsigned int, call)
1193 __field(enum rxrpc_recvmsg_trace, why)
1194 __field(int, ret)
faf92e8d
DH
1195 ),
1196
1197 TP_fast_assign(
0e50d999 1198 __entry->call = call_debug_id;
faf92e8d
DH
1199 __entry->why = why;
1200 __entry->ret = ret;
1201 ),
1202
1203 TP_printk("c=%08x %s ret=%d",
1204 __entry->call,
1205 __print_symbolic(__entry->why, rxrpc_recvmsg_traces),
1206 __entry->ret)
1207 );
1208
1209TRACE_EVENT(rxrpc_recvdata,
84997905
DH
1210 TP_PROTO(struct rxrpc_call *call, enum rxrpc_recvmsg_trace why,
1211 rxrpc_seq_t seq, unsigned int offset, unsigned int len,
1212 int ret),
1213
1214 TP_ARGS(call, why, seq, offset, len, ret),
1215
1216 TP_STRUCT__entry(
371e68ba
DH
1217 __field(unsigned int, call)
1218 __field(enum rxrpc_recvmsg_trace, why)
1219 __field(rxrpc_seq_t, seq)
1220 __field(unsigned int, offset)
1221 __field(unsigned int, len)
1222 __field(int, ret)
84997905
DH
1223 ),
1224
1225 TP_fast_assign(
db9b2e0a 1226 __entry->call = call ? call->debug_id : 0;
84997905
DH
1227 __entry->why = why;
1228 __entry->seq = seq;
1229 __entry->offset = offset;
1230 __entry->len = len;
1231 __entry->ret = ret;
1232 ),
1233
a25e21f0 1234 TP_printk("c=%08x %s q=%08x o=%u l=%u ret=%d",
84997905 1235 __entry->call,
b54a134a 1236 __print_symbolic(__entry->why, rxrpc_recvmsg_traces),
84997905
DH
1237 __entry->seq,
1238 __entry->offset,
1239 __entry->len,
1240 __entry->ret)
1241 );
1242
cf1a6474
DH
1243TRACE_EVENT(rxrpc_rtt_tx,
1244 TP_PROTO(struct rxrpc_call *call, enum rxrpc_rtt_tx_trace why,
4700c4d8 1245 int slot, rxrpc_serial_t send_serial),
cf1a6474 1246
4700c4d8 1247 TP_ARGS(call, why, slot, send_serial),
cf1a6474
DH
1248
1249 TP_STRUCT__entry(
371e68ba
DH
1250 __field(unsigned int, call)
1251 __field(enum rxrpc_rtt_tx_trace, why)
1252 __field(int, slot)
1253 __field(rxrpc_serial_t, send_serial)
cf1a6474
DH
1254 ),
1255
1256 TP_fast_assign(
a25e21f0 1257 __entry->call = call->debug_id;
cf1a6474 1258 __entry->why = why;
4700c4d8 1259 __entry->slot = slot;
cf1a6474
DH
1260 __entry->send_serial = send_serial;
1261 ),
1262
4700c4d8 1263 TP_printk("c=%08x [%d] %s sr=%08x",
cf1a6474 1264 __entry->call,
4700c4d8 1265 __entry->slot,
b54a134a 1266 __print_symbolic(__entry->why, rxrpc_rtt_tx_traces),
cf1a6474
DH
1267 __entry->send_serial)
1268 );
1269
1270TRACE_EVENT(rxrpc_rtt_rx,
1271 TP_PROTO(struct rxrpc_call *call, enum rxrpc_rtt_rx_trace why,
4700c4d8 1272 int slot,
cf1a6474 1273 rxrpc_serial_t send_serial, rxrpc_serial_t resp_serial,
c410bf01 1274 u32 rtt, u32 rto),
cf1a6474 1275
4700c4d8 1276 TP_ARGS(call, why, slot, send_serial, resp_serial, rtt, rto),
cf1a6474
DH
1277
1278 TP_STRUCT__entry(
371e68ba
DH
1279 __field(unsigned int, call)
1280 __field(enum rxrpc_rtt_rx_trace, why)
1281 __field(int, slot)
1282 __field(rxrpc_serial_t, send_serial)
1283 __field(rxrpc_serial_t, resp_serial)
1284 __field(u32, rtt)
1285 __field(u32, rto)
cf1a6474
DH
1286 ),
1287
1288 TP_fast_assign(
a25e21f0 1289 __entry->call = call->debug_id;
cf1a6474 1290 __entry->why = why;
4700c4d8 1291 __entry->slot = slot;
cf1a6474
DH
1292 __entry->send_serial = send_serial;
1293 __entry->resp_serial = resp_serial;
1294 __entry->rtt = rtt;
c410bf01 1295 __entry->rto = rto;
cf1a6474
DH
1296 ),
1297
4700c4d8 1298 TP_printk("c=%08x [%d] %s sr=%08x rr=%08x rtt=%u rto=%u",
cf1a6474 1299 __entry->call,
4700c4d8 1300 __entry->slot,
b54a134a 1301 __print_symbolic(__entry->why, rxrpc_rtt_rx_traces),
cf1a6474
DH
1302 __entry->send_serial,
1303 __entry->resp_serial,
1304 __entry->rtt,
c410bf01 1305 __entry->rto)
cf1a6474
DH
1306 );
1307
fc7ab6d2
DH
1308TRACE_EVENT(rxrpc_timer,
1309 TP_PROTO(struct rxrpc_call *call, enum rxrpc_timer_trace why,
a158bdd3 1310 unsigned long now),
fc7ab6d2 1311
a158bdd3 1312 TP_ARGS(call, why, now),
fc7ab6d2
DH
1313
1314 TP_STRUCT__entry(
828bebc8
DH
1315 __field(unsigned int, call)
1316 __field(enum rxrpc_timer_trace, why)
1317 __field(long, now)
1318 __field(long, ack_at)
1319 __field(long, ack_lost_at)
1320 __field(long, resend_at)
1321 __field(long, ping_at)
1322 __field(long, expect_rx_by)
1323 __field(long, expect_req_by)
1324 __field(long, expect_term_by)
1325 __field(long, timer)
fc7ab6d2
DH
1326 ),
1327
1328 TP_fast_assign(
a25e21f0 1329 __entry->call = call->debug_id;
a158bdd3
DH
1330 __entry->why = why;
1331 __entry->now = now;
530403d9 1332 __entry->ack_at = call->delay_ack_at;
bd1fdf8c 1333 __entry->ack_lost_at = call->ack_lost_at;
a158bdd3
DH
1334 __entry->resend_at = call->resend_at;
1335 __entry->expect_rx_by = call->expect_rx_by;
1336 __entry->expect_req_by = call->expect_req_by;
1337 __entry->expect_term_by = call->expect_term_by;
1338 __entry->timer = call->timer.expires;
fc7ab6d2
DH
1339 ),
1340
a25e21f0 1341 TP_printk("c=%08x %s a=%ld la=%ld r=%ld xr=%ld xq=%ld xt=%ld t=%ld",
fc7ab6d2 1342 __entry->call,
b54a134a 1343 __print_symbolic(__entry->why, rxrpc_timer_traces),
a158bdd3 1344 __entry->ack_at - __entry->now,
bd1fdf8c 1345 __entry->ack_lost_at - __entry->now,
a158bdd3
DH
1346 __entry->resend_at - __entry->now,
1347 __entry->expect_rx_by - __entry->now,
1348 __entry->expect_req_by - __entry->now,
1349 __entry->expect_term_by - __entry->now,
1350 __entry->timer - __entry->now)
fc7ab6d2
DH
1351 );
1352
334dfbfc
DH
1353TRACE_EVENT(rxrpc_timer_expired,
1354 TP_PROTO(struct rxrpc_call *call, unsigned long now),
1355
1356 TP_ARGS(call, now),
1357
1358 TP_STRUCT__entry(
828bebc8
DH
1359 __field(unsigned int, call)
1360 __field(long, now)
1361 __field(long, ack_at)
1362 __field(long, ack_lost_at)
1363 __field(long, resend_at)
1364 __field(long, ping_at)
1365 __field(long, expect_rx_by)
1366 __field(long, expect_req_by)
1367 __field(long, expect_term_by)
1368 __field(long, timer)
334dfbfc
DH
1369 ),
1370
1371 TP_fast_assign(
1372 __entry->call = call->debug_id;
1373 __entry->now = now;
530403d9 1374 __entry->ack_at = call->delay_ack_at;
334dfbfc
DH
1375 __entry->ack_lost_at = call->ack_lost_at;
1376 __entry->resend_at = call->resend_at;
1377 __entry->expect_rx_by = call->expect_rx_by;
1378 __entry->expect_req_by = call->expect_req_by;
1379 __entry->expect_term_by = call->expect_term_by;
1380 __entry->timer = call->timer.expires;
1381 ),
1382
1383 TP_printk("c=%08x EXPIRED a=%ld la=%ld r=%ld xr=%ld xq=%ld xt=%ld t=%ld",
1384 __entry->call,
1385 __entry->ack_at - __entry->now,
1386 __entry->ack_lost_at - __entry->now,
1387 __entry->resend_at - __entry->now,
1388 __entry->expect_rx_by - __entry->now,
1389 __entry->expect_req_by - __entry->now,
1390 __entry->expect_term_by - __entry->now,
1391 __entry->timer - __entry->now)
1392 );
1393
89b475ab
DH
1394TRACE_EVENT(rxrpc_rx_lose,
1395 TP_PROTO(struct rxrpc_skb_priv *sp),
1396
1397 TP_ARGS(sp),
1398
1399 TP_STRUCT__entry(
371e68ba 1400 __field_struct(struct rxrpc_host_header, hdr)
89b475ab
DH
1401 ),
1402
1403 TP_fast_assign(
1404 memcpy(&__entry->hdr, &sp->hdr, sizeof(__entry->hdr));
1405 ),
1406
1407 TP_printk("%08x:%08x:%08x:%04x %08x %08x %02x %02x %s *LOSE*",
1408 __entry->hdr.epoch, __entry->hdr.cid,
1409 __entry->hdr.callNumber, __entry->hdr.serviceId,
1410 __entry->hdr.serial, __entry->hdr.seq,
1411 __entry->hdr.type, __entry->hdr.flags,
b54a134a
DH
1412 __entry->hdr.type <= 15 ?
1413 __print_symbolic(__entry->hdr.type, rxrpc_pkts) : "?UNK")
89b475ab
DH
1414 );
1415
9c7ad434
DH
1416TRACE_EVENT(rxrpc_propose_ack,
1417 TP_PROTO(struct rxrpc_call *call, enum rxrpc_propose_ack_trace why,
530403d9 1418 u8 ack_reason, rxrpc_serial_t serial),
9c7ad434 1419
530403d9 1420 TP_ARGS(call, why, ack_reason, serial),
9c7ad434
DH
1421
1422 TP_STRUCT__entry(
371e68ba
DH
1423 __field(unsigned int, call)
1424 __field(enum rxrpc_propose_ack_trace, why)
1425 __field(rxrpc_serial_t, serial)
1426 __field(u8, ack_reason)
9c7ad434
DH
1427 ),
1428
1429 TP_fast_assign(
a25e21f0 1430 __entry->call = call->debug_id;
9c7ad434
DH
1431 __entry->why = why;
1432 __entry->serial = serial;
1433 __entry->ack_reason = ack_reason;
9c7ad434
DH
1434 ),
1435
530403d9 1436 TP_printk("c=%08x %s %s r=%08x",
9c7ad434 1437 __entry->call,
b54a134a
DH
1438 __print_symbolic(__entry->why, rxrpc_propose_ack_traces),
1439 __print_symbolic(__entry->ack_reason, rxrpc_ack_names),
530403d9 1440 __entry->serial)
9c7ad434
DH
1441 );
1442
72f0c6fb
DH
1443TRACE_EVENT(rxrpc_send_ack,
1444 TP_PROTO(struct rxrpc_call *call, enum rxrpc_propose_ack_trace why,
1445 u8 ack_reason, rxrpc_serial_t serial),
1446
1447 TP_ARGS(call, why, ack_reason, serial),
1448
1449 TP_STRUCT__entry(
371e68ba
DH
1450 __field(unsigned int, call)
1451 __field(enum rxrpc_propose_ack_trace, why)
1452 __field(rxrpc_serial_t, serial)
1453 __field(u8, ack_reason)
72f0c6fb
DH
1454 ),
1455
1456 TP_fast_assign(
1457 __entry->call = call->debug_id;
1458 __entry->why = why;
1459 __entry->serial = serial;
1460 __entry->ack_reason = ack_reason;
1461 ),
1462
1463 TP_printk("c=%08x %s %s r=%08x",
1464 __entry->call,
1465 __print_symbolic(__entry->why, rxrpc_propose_ack_traces),
1466 __print_symbolic(__entry->ack_reason, rxrpc_ack_names),
1467 __entry->serial)
1468 );
1469
530403d9
DH
1470TRACE_EVENT(rxrpc_drop_ack,
1471 TP_PROTO(struct rxrpc_call *call, enum rxrpc_propose_ack_trace why,
1472 u8 ack_reason, rxrpc_serial_t serial, bool nobuf),
1473
1474 TP_ARGS(call, why, ack_reason, serial, nobuf),
1475
1476 TP_STRUCT__entry(
371e68ba
DH
1477 __field(unsigned int, call)
1478 __field(enum rxrpc_propose_ack_trace, why)
1479 __field(rxrpc_serial_t, serial)
1480 __field(u8, ack_reason)
1481 __field(bool, nobuf)
530403d9
DH
1482 ),
1483
1484 TP_fast_assign(
1485 __entry->call = call->debug_id;
1486 __entry->why = why;
1487 __entry->serial = serial;
1488 __entry->ack_reason = ack_reason;
1489 __entry->nobuf = nobuf;
1490 ),
1491
1492 TP_printk("c=%08x %s %s r=%08x nbf=%u",
1493 __entry->call,
1494 __print_symbolic(__entry->why, rxrpc_propose_ack_traces),
1495 __print_symbolic(__entry->ack_reason, rxrpc_ack_names),
1496 __entry->serial, __entry->nobuf)
1497 );
1498
c6672e3f 1499TRACE_EVENT(rxrpc_retransmit,
a4ea4c47 1500 TP_PROTO(struct rxrpc_call *call, rxrpc_seq_t seq, s64 expiry),
c6672e3f 1501
a4ea4c47 1502 TP_ARGS(call, seq, expiry),
c6672e3f
DH
1503
1504 TP_STRUCT__entry(
828bebc8
DH
1505 __field(unsigned int, call)
1506 __field(rxrpc_seq_t, seq)
1507 __field(s64, expiry)
c6672e3f
DH
1508 ),
1509
1510 TP_fast_assign(
a25e21f0 1511 __entry->call = call->debug_id;
c6672e3f 1512 __entry->seq = seq;
c6672e3f
DH
1513 __entry->expiry = expiry;
1514 ),
1515
a4ea4c47 1516 TP_printk("c=%08x q=%x xp=%lld",
c6672e3f
DH
1517 __entry->call,
1518 __entry->seq,
c6672e3f
DH
1519 __entry->expiry)
1520 );
1521
57494343
DH
1522TRACE_EVENT(rxrpc_congest,
1523 TP_PROTO(struct rxrpc_call *call, struct rxrpc_ack_summary *summary,
1524 rxrpc_serial_t ack_serial, enum rxrpc_congest_change change),
1525
1526 TP_ARGS(call, summary, ack_serial, change),
1527
1528 TP_STRUCT__entry(
371e68ba
DH
1529 __field(unsigned int, call)
1530 __field(enum rxrpc_congest_change, change)
1531 __field(rxrpc_seq_t, hard_ack)
1532 __field(rxrpc_seq_t, top)
1533 __field(rxrpc_seq_t, lowest_nak)
1534 __field(rxrpc_serial_t, ack_serial)
1535 __field_struct(struct rxrpc_ack_summary, sum)
57494343
DH
1536 ),
1537
1538 TP_fast_assign(
a25e21f0 1539 __entry->call = call->debug_id;
57494343 1540 __entry->change = change;
a4ea4c47 1541 __entry->hard_ack = call->acks_hard_ack;
57494343
DH
1542 __entry->top = call->tx_top;
1543 __entry->lowest_nak = call->acks_lowest_nak;
1544 __entry->ack_serial = ack_serial;
1545 memcpy(&__entry->sum, summary, sizeof(__entry->sum));
1546 ),
1547
d57a3a15 1548 TP_printk("c=%08x r=%08x %s q=%08x %s cw=%u ss=%u nA=%u,%u+%u r=%u b=%u u=%u d=%u l=%x%s%s%s",
57494343
DH
1549 __entry->call,
1550 __entry->ack_serial,
b54a134a 1551 __print_symbolic(__entry->sum.ack_reason, rxrpc_ack_names),
57494343 1552 __entry->hard_ack,
b54a134a 1553 __print_symbolic(__entry->sum.mode, rxrpc_congest_modes),
57494343
DH
1554 __entry->sum.cwnd,
1555 __entry->sum.ssthresh,
d57a3a15
DH
1556 __entry->sum.nr_acks, __entry->sum.saw_nacks,
1557 __entry->sum.nr_new_acks,
57494343
DH
1558 __entry->sum.nr_rot_new_acks,
1559 __entry->top - __entry->hard_ack,
1560 __entry->sum.cumulative_acks,
1561 __entry->sum.dup_acks,
1562 __entry->lowest_nak, __entry->sum.new_low_nack ? "!" : "",
b54a134a 1563 __print_symbolic(__entry->change, rxrpc_congest_changes),
57494343
DH
1564 __entry->sum.retrans_timeo ? " rTxTo" : "")
1565 );
1566
32cf8edb
DH
1567TRACE_EVENT(rxrpc_reset_cwnd,
1568 TP_PROTO(struct rxrpc_call *call, ktime_t now),
1569
1570 TP_ARGS(call, now),
1571
1572 TP_STRUCT__entry(
828bebc8
DH
1573 __field(unsigned int, call)
1574 __field(enum rxrpc_congest_mode, mode)
1575 __field(unsigned short, cwnd)
1576 __field(unsigned short, extra)
1577 __field(rxrpc_seq_t, hard_ack)
1578 __field(rxrpc_seq_t, prepared)
1579 __field(ktime_t, since_last_tx)
1580 __field(bool, has_data)
32cf8edb
DH
1581 ),
1582
1583 TP_fast_assign(
1584 __entry->call = call->debug_id;
1585 __entry->mode = call->cong_mode;
1586 __entry->cwnd = call->cong_cwnd;
1587 __entry->extra = call->cong_extra;
1588 __entry->hard_ack = call->acks_hard_ack;
1589 __entry->prepared = call->tx_prepared - call->tx_bottom;
1590 __entry->since_last_tx = ktime_sub(now, call->tx_last_sent);
1591 __entry->has_data = !list_empty(&call->tx_sendmsg);
1592 ),
1593
1594 TP_printk("c=%08x q=%08x %s cw=%u+%u pr=%u tm=%llu d=%u",
1595 __entry->call,
1596 __entry->hard_ack,
1597 __print_symbolic(__entry->mode, rxrpc_congest_modes),
1598 __entry->cwnd,
1599 __entry->extra,
1600 __entry->prepared,
1601 ktime_to_ns(__entry->since_last_tx),
1602 __entry->has_data)
1603 );
1604
b1d9f7fd
DH
1605TRACE_EVENT(rxrpc_disconnect_call,
1606 TP_PROTO(struct rxrpc_call *call),
1607
1608 TP_ARGS(call),
1609
1610 TP_STRUCT__entry(
828bebc8
DH
1611 __field(unsigned int, call)
1612 __field(u32, abort_code)
b1d9f7fd
DH
1613 ),
1614
1615 TP_fast_assign(
a25e21f0 1616 __entry->call = call->debug_id;
b1d9f7fd
DH
1617 __entry->abort_code = call->abort_code;
1618 ),
1619
a25e21f0 1620 TP_printk("c=%08x ab=%08x",
b1d9f7fd
DH
1621 __entry->call,
1622 __entry->abort_code)
1623 );
1624
1625TRACE_EVENT(rxrpc_improper_term,
1626 TP_PROTO(struct rxrpc_call *call),
1627
1628 TP_ARGS(call),
1629
1630 TP_STRUCT__entry(
828bebc8
DH
1631 __field(unsigned int, call)
1632 __field(u32, abort_code)
b1d9f7fd
DH
1633 ),
1634
1635 TP_fast_assign(
a25e21f0 1636 __entry->call = call->debug_id;
b1d9f7fd
DH
1637 __entry->abort_code = call->abort_code;
1638 ),
1639
a25e21f0 1640 TP_printk("c=%08x ab=%08x",
b1d9f7fd
DH
1641 __entry->call,
1642 __entry->abort_code)
1643 );
1644
89ca6948
DH
1645TRACE_EVENT(rxrpc_connect_call,
1646 TP_PROTO(struct rxrpc_call *call),
1647
1648 TP_ARGS(call),
1649
1650 TP_STRUCT__entry(
371e68ba
DH
1651 __field(unsigned int, call)
1652 __field(unsigned long, user_call_ID)
1653 __field(u32, cid)
1654 __field(u32, call_id)
1655 __field_struct(struct sockaddr_rxrpc, srx)
89ca6948
DH
1656 ),
1657
1658 TP_fast_assign(
a25e21f0 1659 __entry->call = call->debug_id;
89ca6948
DH
1660 __entry->user_call_ID = call->user_call_ID;
1661 __entry->cid = call->cid;
1662 __entry->call_id = call->call_id;
5e6ef4f1 1663 __entry->srx = call->dest_srx;
89ca6948
DH
1664 ),
1665
5e6ef4f1 1666 TP_printk("c=%08x u=%p %08x:%08x dst=%pISp",
89ca6948
DH
1667 __entry->call,
1668 (void *)__entry->user_call_ID,
1669 __entry->cid,
5e6ef4f1
DH
1670 __entry->call_id,
1671 &__entry->srx.transport)
89ca6948
DH
1672 );
1673
827efed6 1674TRACE_EVENT(rxrpc_resend,
5e6ef4f1 1675 TP_PROTO(struct rxrpc_call *call, struct sk_buff *ack),
827efed6 1676
5e6ef4f1 1677 TP_ARGS(call, ack),
827efed6
DH
1678
1679 TP_STRUCT__entry(
828bebc8
DH
1680 __field(unsigned int, call)
1681 __field(rxrpc_seq_t, seq)
1682 __field(rxrpc_seq_t, transmitted)
1683 __field(rxrpc_serial_t, ack_serial)
827efed6
DH
1684 ),
1685
1686 TP_fast_assign(
5e6ef4f1 1687 struct rxrpc_skb_priv *sp = ack ? rxrpc_skb(ack) : NULL;
a25e21f0 1688 __entry->call = call->debug_id;
a4ea4c47 1689 __entry->seq = call->acks_hard_ack;
5e6ef4f1
DH
1690 __entry->transmitted = call->tx_transmitted;
1691 __entry->ack_serial = sp ? sp->hdr.serial : 0;
827efed6
DH
1692 ),
1693
5e6ef4f1 1694 TP_printk("c=%08x r=%x q=%x tq=%x",
827efed6 1695 __entry->call,
5e6ef4f1
DH
1696 __entry->ack_serial,
1697 __entry->seq,
1698 __entry->transmitted)
827efed6
DH
1699 );
1700
494337c9
DH
1701TRACE_EVENT(rxrpc_rx_icmp,
1702 TP_PROTO(struct rxrpc_peer *peer, struct sock_extended_err *ee,
1703 struct sockaddr_rxrpc *srx),
1704
1705 TP_ARGS(peer, ee, srx),
1706
1707 TP_STRUCT__entry(
371e68ba
DH
1708 __field(unsigned int, peer)
1709 __field_struct(struct sock_extended_err, ee)
1710 __field_struct(struct sockaddr_rxrpc, srx)
494337c9
DH
1711 ),
1712
1713 TP_fast_assign(
1714 __entry->peer = peer->debug_id;
1715 memcpy(&__entry->ee, ee, sizeof(__entry->ee));
1716 memcpy(&__entry->srx, srx, sizeof(__entry->srx));
1717 ),
1718
1719 TP_printk("P=%08x o=%u t=%u c=%u i=%u d=%u e=%d %pISp",
1720 __entry->peer,
1721 __entry->ee.ee_origin,
1722 __entry->ee.ee_type,
1723 __entry->ee.ee_code,
1724 __entry->ee.ee_info,
1725 __entry->ee.ee_data,
1726 __entry->ee.ee_errno,
1727 &__entry->srx.transport)
1728 );
1729
6b47fe1d
DH
1730TRACE_EVENT(rxrpc_tx_fail,
1731 TP_PROTO(unsigned int debug_id, rxrpc_serial_t serial, int ret,
4764c0da 1732 enum rxrpc_tx_point where),
6b47fe1d 1733
4764c0da 1734 TP_ARGS(debug_id, serial, ret, where),
6b47fe1d
DH
1735
1736 TP_STRUCT__entry(
371e68ba
DH
1737 __field(unsigned int, debug_id)
1738 __field(rxrpc_serial_t, serial)
1739 __field(int, ret)
1740 __field(enum rxrpc_tx_point, where)
6b47fe1d
DH
1741 ),
1742
1743 TP_fast_assign(
1744 __entry->debug_id = debug_id;
1745 __entry->serial = serial;
1746 __entry->ret = ret;
4764c0da 1747 __entry->where = where;
6b47fe1d
DH
1748 ),
1749
1750 TP_printk("c=%08x r=%x ret=%d %s",
1751 __entry->debug_id,
1752 __entry->serial,
1753 __entry->ret,
4764c0da 1754 __print_symbolic(__entry->where, rxrpc_tx_points))
6b47fe1d
DH
1755 );
1756
1a025028
DH
1757TRACE_EVENT(rxrpc_call_reset,
1758 TP_PROTO(struct rxrpc_call *call),
1759
1760 TP_ARGS(call),
1761
1762 TP_STRUCT__entry(
828bebc8
DH
1763 __field(unsigned int, debug_id)
1764 __field(u32, cid)
1765 __field(u32, call_id)
1766 __field(rxrpc_serial_t, call_serial)
1767 __field(rxrpc_serial_t, conn_serial)
1768 __field(rxrpc_seq_t, tx_seq)
1769 __field(rxrpc_seq_t, rx_seq)
1a025028
DH
1770 ),
1771
1772 TP_fast_assign(
1773 __entry->debug_id = call->debug_id;
1774 __entry->cid = call->cid;
1775 __entry->call_id = call->call_id;
1776 __entry->call_serial = call->rx_serial;
1777 __entry->conn_serial = call->conn->hi_serial;
a4ea4c47 1778 __entry->tx_seq = call->acks_hard_ack;
5d7edbc9 1779 __entry->rx_seq = call->rx_highest_seq;
1a025028
DH
1780 ),
1781
1782 TP_printk("c=%08x %08x:%08x r=%08x/%08x tx=%08x rx=%08x",
1783 __entry->debug_id,
1784 __entry->cid, __entry->call_id,
1785 __entry->call_serial, __entry->conn_serial,
1786 __entry->tx_seq, __entry->rx_seq)
1787 );
1788
4272d303
DH
1789TRACE_EVENT(rxrpc_notify_socket,
1790 TP_PROTO(unsigned int debug_id, rxrpc_serial_t serial),
1791
1792 TP_ARGS(debug_id, serial),
1793
1794 TP_STRUCT__entry(
828bebc8
DH
1795 __field(unsigned int, debug_id)
1796 __field(rxrpc_serial_t, serial)
4272d303
DH
1797 ),
1798
1799 TP_fast_assign(
1800 __entry->debug_id = debug_id;
1801 __entry->serial = serial;
1802 ),
1803
1804 TP_printk("c=%08x r=%08x",
1805 __entry->debug_id,
1806 __entry->serial)
1807 );
1808
d1f12947
DH
1809TRACE_EVENT(rxrpc_rx_discard_ack,
1810 TP_PROTO(unsigned int debug_id, rxrpc_serial_t serial,
1811 rxrpc_seq_t first_soft_ack, rxrpc_seq_t call_ackr_first,
1812 rxrpc_seq_t prev_pkt, rxrpc_seq_t call_ackr_prev),
1813
1814 TP_ARGS(debug_id, serial, first_soft_ack, call_ackr_first,
1815 prev_pkt, call_ackr_prev),
1816
1817 TP_STRUCT__entry(
371e68ba
DH
1818 __field(unsigned int, debug_id)
1819 __field(rxrpc_serial_t, serial)
d1f12947
DH
1820 __field(rxrpc_seq_t, first_soft_ack)
1821 __field(rxrpc_seq_t, call_ackr_first)
1822 __field(rxrpc_seq_t, prev_pkt)
1823 __field(rxrpc_seq_t, call_ackr_prev)
1824 ),
1825
1826 TP_fast_assign(
1827 __entry->debug_id = debug_id;
1828 __entry->serial = serial;
1829 __entry->first_soft_ack = first_soft_ack;
1830 __entry->call_ackr_first = call_ackr_first;
1831 __entry->prev_pkt = prev_pkt;
1832 __entry->call_ackr_prev = call_ackr_prev;
1833 ),
1834
1835 TP_printk("c=%08x r=%08x %08x<%08x %08x<%08x",
1836 __entry->debug_id,
1837 __entry->serial,
1838 __entry->first_soft_ack,
1839 __entry->call_ackr_first,
1840 __entry->prev_pkt,
1841 __entry->call_ackr_prev)
1842 );
1843
4d843be5
DH
1844TRACE_EVENT(rxrpc_req_ack,
1845 TP_PROTO(unsigned int call_debug_id, rxrpc_seq_t seq,
1846 enum rxrpc_req_ack_trace why),
1847
1848 TP_ARGS(call_debug_id, seq, why),
1849
1850 TP_STRUCT__entry(
371e68ba
DH
1851 __field(unsigned int, call_debug_id)
1852 __field(rxrpc_seq_t, seq)
1853 __field(enum rxrpc_req_ack_trace, why)
4d843be5
DH
1854 ),
1855
1856 TP_fast_assign(
1857 __entry->call_debug_id = call_debug_id;
1858 __entry->seq = seq;
1859 __entry->why = why;
1860 ),
1861
1862 TP_printk("c=%08x q=%08x REQ-%s",
1863 __entry->call_debug_id,
1864 __entry->seq,
1865 __print_symbolic(__entry->why, rxrpc_req_ack_traces))
1866 );
1867
02a19356
DH
1868TRACE_EVENT(rxrpc_txbuf,
1869 TP_PROTO(unsigned int debug_id,
1870 unsigned int call_debug_id, rxrpc_seq_t seq,
1871 int ref, enum rxrpc_txbuf_trace what),
1872
1873 TP_ARGS(debug_id, call_debug_id, seq, ref, what),
1874
1875 TP_STRUCT__entry(
371e68ba
DH
1876 __field(unsigned int, debug_id)
1877 __field(unsigned int, call_debug_id)
1878 __field(rxrpc_seq_t, seq)
1879 __field(int, ref)
1880 __field(enum rxrpc_txbuf_trace, what)
02a19356
DH
1881 ),
1882
1883 TP_fast_assign(
1884 __entry->debug_id = debug_id;
1885 __entry->call_debug_id = call_debug_id;
1886 __entry->seq = seq;
1887 __entry->ref = ref;
1888 __entry->what = what;
1889 ),
1890
1891 TP_printk("B=%08x c=%08x q=%08x %s r=%d",
1892 __entry->debug_id,
1893 __entry->call_debug_id,
1894 __entry->seq,
1895 __print_symbolic(__entry->what, rxrpc_txbuf_traces),
1896 __entry->ref)
1897 );
1898
15f661dc
DH
1899TRACE_EVENT(rxrpc_poke_call,
1900 TP_PROTO(struct rxrpc_call *call, bool busy,
1901 enum rxrpc_call_poke_trace what),
1902
1903 TP_ARGS(call, busy, what),
1904
1905 TP_STRUCT__entry(
371e68ba
DH
1906 __field(unsigned int, call_debug_id)
1907 __field(bool, busy)
1908 __field(enum rxrpc_call_poke_trace, what)
15f661dc
DH
1909 ),
1910
1911 TP_fast_assign(
1912 __entry->call_debug_id = call->debug_id;
1913 __entry->busy = busy;
1914 __entry->what = what;
1915 ),
1916
1917 TP_printk("c=%08x %s%s",
1918 __entry->call_debug_id,
1919 __print_symbolic(__entry->what, rxrpc_call_poke_traces),
1920 __entry->busy ? "!" : "")
1921 );
1922
1923TRACE_EVENT(rxrpc_call_poked,
1924 TP_PROTO(struct rxrpc_call *call),
1925
1926 TP_ARGS(call),
1927
1928 TP_STRUCT__entry(
828bebc8 1929 __field(unsigned int, call_debug_id)
15f661dc
DH
1930 ),
1931
1932 TP_fast_assign(
1933 __entry->call_debug_id = call->debug_id;
1934 ),
1935
1936 TP_printk("c=%08x",
1937 __entry->call_debug_id)
1938 );
1939
f21e9348
DH
1940TRACE_EVENT(rxrpc_sack,
1941 TP_PROTO(struct rxrpc_call *call, rxrpc_seq_t seq,
1942 unsigned int sack, enum rxrpc_sack_trace what),
1943
1944 TP_ARGS(call, seq, sack, what),
1945
1946 TP_STRUCT__entry(
1947 __field(unsigned int, call_debug_id)
1948 __field(rxrpc_seq_t, seq)
1949 __field(unsigned int, sack)
1950 __field(enum rxrpc_sack_trace, what)
1951 ),
1952
1953 TP_fast_assign(
1954 __entry->call_debug_id = call->debug_id;
1955 __entry->seq = seq;
1956 __entry->sack = sack;
1957 __entry->what = what;
1958 ),
1959
1960 TP_printk("c=%08x q=%08x %s k=%x",
1961 __entry->call_debug_id,
1962 __entry->seq,
1963 __print_symbolic(__entry->what, rxrpc_sack_traces),
1964 __entry->sack)
1965 );
1966
dc9fd093
DH
1967#undef EM
1968#undef E_
57af281e
DH
1969
1970#endif /* RXRPC_TRACE_ONLY_DEFINE_ENUMS */
df844fd4
DH
1971#endif /* _TRACE_RXRPC_H */
1972
1973/* This part must be outside protection */
1974#include <trace/define_trace.h>