xref: /openbmc/linux/include/trace/events/rxrpc.h (revision 494337c918403db5743af0348d963cafb9b20cee)
1df844fd4SDavid Howells /* AF_RXRPC tracepoints
2df844fd4SDavid Howells  *
3df844fd4SDavid Howells  * Copyright (C) 2016 Red Hat, Inc. All Rights Reserved.
4df844fd4SDavid Howells  * Written by David Howells (dhowells@redhat.com)
5df844fd4SDavid Howells  *
6df844fd4SDavid Howells  * This program is free software; you can redistribute it and/or
7df844fd4SDavid Howells  * modify it under the terms of the GNU General Public Licence
8df844fd4SDavid Howells  * as published by the Free Software Foundation; either version
9df844fd4SDavid Howells  * 2 of the Licence, or (at your option) any later version.
10df844fd4SDavid Howells  */
11df844fd4SDavid Howells #undef TRACE_SYSTEM
12df844fd4SDavid Howells #define TRACE_SYSTEM rxrpc
13df844fd4SDavid Howells 
14df844fd4SDavid Howells #if !defined(_TRACE_RXRPC_H) || defined(TRACE_HEADER_MULTI_READ)
15df844fd4SDavid Howells #define _TRACE_RXRPC_H
16df844fd4SDavid Howells 
17df844fd4SDavid Howells #include <linux/tracepoint.h>
18*494337c9SDavid Howells #include <linux/errqueue.h>
19df844fd4SDavid Howells 
20b54a134aSDavid Howells /*
21b54a134aSDavid Howells  * Define enums for tracing information.
22b54a134aSDavid Howells  *
23b54a134aSDavid Howells  * These should all be kept sorted, making it easier to match the string
24b54a134aSDavid Howells  * mapping tables further on.
25b54a134aSDavid Howells  */
26b54a134aSDavid Howells #ifndef __RXRPC_DECLARE_TRACE_ENUMS_ONCE_ONLY
27b54a134aSDavid Howells #define __RXRPC_DECLARE_TRACE_ENUMS_ONCE_ONLY
28b54a134aSDavid Howells 
29b54a134aSDavid Howells enum rxrpc_skb_trace {
30b54a134aSDavid Howells 	rxrpc_skb_rx_cleaned,
31b54a134aSDavid Howells 	rxrpc_skb_rx_freed,
32b54a134aSDavid Howells 	rxrpc_skb_rx_got,
33b54a134aSDavid Howells 	rxrpc_skb_rx_lost,
34b54a134aSDavid Howells 	rxrpc_skb_rx_purged,
35b54a134aSDavid Howells 	rxrpc_skb_rx_received,
36b54a134aSDavid Howells 	rxrpc_skb_rx_rotated,
37b54a134aSDavid Howells 	rxrpc_skb_rx_seen,
38b54a134aSDavid Howells 	rxrpc_skb_tx_cleaned,
39b54a134aSDavid Howells 	rxrpc_skb_tx_freed,
40b54a134aSDavid Howells 	rxrpc_skb_tx_got,
41b54a134aSDavid Howells 	rxrpc_skb_tx_new,
42b54a134aSDavid Howells 	rxrpc_skb_tx_rotated,
43b54a134aSDavid Howells 	rxrpc_skb_tx_seen,
44b54a134aSDavid Howells };
45b54a134aSDavid Howells 
4609d2bf59SDavid Howells enum rxrpc_local_trace {
4709d2bf59SDavid Howells 	rxrpc_local_got,
4809d2bf59SDavid Howells 	rxrpc_local_new,
4909d2bf59SDavid Howells 	rxrpc_local_processing,
5009d2bf59SDavid Howells 	rxrpc_local_put,
5109d2bf59SDavid Howells 	rxrpc_local_queued,
5209d2bf59SDavid Howells };
5309d2bf59SDavid Howells 
541159d4b4SDavid Howells enum rxrpc_peer_trace {
551159d4b4SDavid Howells 	rxrpc_peer_got,
561159d4b4SDavid Howells 	rxrpc_peer_new,
571159d4b4SDavid Howells 	rxrpc_peer_processing,
581159d4b4SDavid Howells 	rxrpc_peer_put,
591159d4b4SDavid Howells 	rxrpc_peer_queued_error,
601159d4b4SDavid Howells };
611159d4b4SDavid Howells 
62b54a134aSDavid Howells enum rxrpc_conn_trace {
63b54a134aSDavid Howells 	rxrpc_conn_got,
64b54a134aSDavid Howells 	rxrpc_conn_new_client,
65b54a134aSDavid Howells 	rxrpc_conn_new_service,
66b54a134aSDavid Howells 	rxrpc_conn_put_client,
67b54a134aSDavid Howells 	rxrpc_conn_put_service,
68b54a134aSDavid Howells 	rxrpc_conn_queued,
69f859ab61SDavid Howells 	rxrpc_conn_reap_service,
70b54a134aSDavid Howells 	rxrpc_conn_seen,
71b54a134aSDavid Howells };
72b54a134aSDavid Howells 
73b54a134aSDavid Howells enum rxrpc_client_trace {
74b54a134aSDavid Howells 	rxrpc_client_activate_chans,
75b54a134aSDavid Howells 	rxrpc_client_alloc,
76b54a134aSDavid Howells 	rxrpc_client_chan_activate,
77b54a134aSDavid Howells 	rxrpc_client_chan_disconnect,
78b54a134aSDavid Howells 	rxrpc_client_chan_pass,
79b54a134aSDavid Howells 	rxrpc_client_chan_unstarted,
80b54a134aSDavid Howells 	rxrpc_client_cleanup,
81b54a134aSDavid Howells 	rxrpc_client_count,
82b54a134aSDavid Howells 	rxrpc_client_discard,
83b54a134aSDavid Howells 	rxrpc_client_duplicate,
84b54a134aSDavid Howells 	rxrpc_client_exposed,
85b54a134aSDavid Howells 	rxrpc_client_replace,
86b54a134aSDavid Howells 	rxrpc_client_to_active,
87b54a134aSDavid Howells 	rxrpc_client_to_culled,
88b54a134aSDavid Howells 	rxrpc_client_to_idle,
89b54a134aSDavid Howells 	rxrpc_client_to_inactive,
90b54a134aSDavid Howells 	rxrpc_client_to_upgrade,
91b54a134aSDavid Howells 	rxrpc_client_to_waiting,
92b54a134aSDavid Howells 	rxrpc_client_uncount,
93b54a134aSDavid Howells };
94b54a134aSDavid Howells 
95b54a134aSDavid Howells enum rxrpc_call_trace {
96b54a134aSDavid Howells 	rxrpc_call_connected,
97b54a134aSDavid Howells 	rxrpc_call_error,
98b54a134aSDavid Howells 	rxrpc_call_got,
99b54a134aSDavid Howells 	rxrpc_call_got_kernel,
100b54a134aSDavid Howells 	rxrpc_call_got_userid,
101b54a134aSDavid Howells 	rxrpc_call_new_client,
102b54a134aSDavid Howells 	rxrpc_call_new_service,
103b54a134aSDavid Howells 	rxrpc_call_put,
104b54a134aSDavid Howells 	rxrpc_call_put_kernel,
105b54a134aSDavid Howells 	rxrpc_call_put_noqueue,
106b54a134aSDavid Howells 	rxrpc_call_put_userid,
107b54a134aSDavid Howells 	rxrpc_call_queued,
108b54a134aSDavid Howells 	rxrpc_call_queued_ref,
109b54a134aSDavid Howells 	rxrpc_call_release,
110b54a134aSDavid Howells 	rxrpc_call_seen,
111b54a134aSDavid Howells };
112b54a134aSDavid Howells 
113b54a134aSDavid Howells enum rxrpc_transmit_trace {
114b54a134aSDavid Howells 	rxrpc_transmit_await_reply,
115b54a134aSDavid Howells 	rxrpc_transmit_end,
116b54a134aSDavid Howells 	rxrpc_transmit_queue,
117b54a134aSDavid Howells 	rxrpc_transmit_queue_last,
118b54a134aSDavid Howells 	rxrpc_transmit_rotate,
119b54a134aSDavid Howells 	rxrpc_transmit_rotate_last,
120b54a134aSDavid Howells 	rxrpc_transmit_wait,
121b54a134aSDavid Howells };
122b54a134aSDavid Howells 
123b54a134aSDavid Howells enum rxrpc_receive_trace {
124b54a134aSDavid Howells 	rxrpc_receive_end,
125b54a134aSDavid Howells 	rxrpc_receive_front,
126b54a134aSDavid Howells 	rxrpc_receive_incoming,
127b54a134aSDavid Howells 	rxrpc_receive_queue,
128b54a134aSDavid Howells 	rxrpc_receive_queue_last,
129b54a134aSDavid Howells 	rxrpc_receive_rotate,
130b54a134aSDavid Howells };
131b54a134aSDavid Howells 
132b54a134aSDavid Howells enum rxrpc_recvmsg_trace {
133b54a134aSDavid Howells 	rxrpc_recvmsg_cont,
134b54a134aSDavid Howells 	rxrpc_recvmsg_data_return,
135b54a134aSDavid Howells 	rxrpc_recvmsg_dequeue,
136b54a134aSDavid Howells 	rxrpc_recvmsg_enter,
137b54a134aSDavid Howells 	rxrpc_recvmsg_full,
138b54a134aSDavid Howells 	rxrpc_recvmsg_hole,
139b54a134aSDavid Howells 	rxrpc_recvmsg_next,
140540b1c48SDavid Howells 	rxrpc_recvmsg_requeue,
141b54a134aSDavid Howells 	rxrpc_recvmsg_return,
142b54a134aSDavid Howells 	rxrpc_recvmsg_terminal,
143b54a134aSDavid Howells 	rxrpc_recvmsg_to_be_accepted,
144b54a134aSDavid Howells 	rxrpc_recvmsg_wait,
145b54a134aSDavid Howells };
146b54a134aSDavid Howells 
147b54a134aSDavid Howells enum rxrpc_rtt_tx_trace {
148b54a134aSDavid Howells 	rxrpc_rtt_tx_data,
149b54a134aSDavid Howells 	rxrpc_rtt_tx_ping,
150b54a134aSDavid Howells };
151b54a134aSDavid Howells 
152b54a134aSDavid Howells enum rxrpc_rtt_rx_trace {
153b54a134aSDavid Howells 	rxrpc_rtt_rx_ping_response,
154b54a134aSDavid Howells 	rxrpc_rtt_rx_requested_ack,
155b54a134aSDavid Howells };
156b54a134aSDavid Howells 
157b54a134aSDavid Howells enum rxrpc_timer_trace {
158b54a134aSDavid Howells 	rxrpc_timer_begin,
159a158bdd3SDavid Howells 	rxrpc_timer_exp_ack,
160a158bdd3SDavid Howells 	rxrpc_timer_exp_hard,
161a158bdd3SDavid Howells 	rxrpc_timer_exp_idle,
162415f44e4SDavid Howells 	rxrpc_timer_exp_keepalive,
163bd1fdf8cSDavid Howells 	rxrpc_timer_exp_lost_ack,
164a158bdd3SDavid Howells 	rxrpc_timer_exp_normal,
165a158bdd3SDavid Howells 	rxrpc_timer_exp_ping,
166a158bdd3SDavid Howells 	rxrpc_timer_exp_resend,
167b54a134aSDavid Howells 	rxrpc_timer_expired,
168b54a134aSDavid Howells 	rxrpc_timer_init_for_reply,
169b54a134aSDavid Howells 	rxrpc_timer_init_for_send_reply,
170a158bdd3SDavid Howells 	rxrpc_timer_restart,
171b54a134aSDavid Howells 	rxrpc_timer_set_for_ack,
172a158bdd3SDavid Howells 	rxrpc_timer_set_for_hard,
173a158bdd3SDavid Howells 	rxrpc_timer_set_for_idle,
174415f44e4SDavid Howells 	rxrpc_timer_set_for_keepalive,
175bd1fdf8cSDavid Howells 	rxrpc_timer_set_for_lost_ack,
176a158bdd3SDavid Howells 	rxrpc_timer_set_for_normal,
177b54a134aSDavid Howells 	rxrpc_timer_set_for_ping,
178b54a134aSDavid Howells 	rxrpc_timer_set_for_resend,
179b54a134aSDavid Howells 	rxrpc_timer_set_for_send,
180b54a134aSDavid Howells };
181b54a134aSDavid Howells 
182b54a134aSDavid Howells enum rxrpc_propose_ack_trace {
183b54a134aSDavid Howells 	rxrpc_propose_ack_client_tx_end,
184b54a134aSDavid Howells 	rxrpc_propose_ack_input_data,
185415f44e4SDavid Howells 	rxrpc_propose_ack_ping_for_keepalive,
186b54a134aSDavid Howells 	rxrpc_propose_ack_ping_for_lost_ack,
187b54a134aSDavid Howells 	rxrpc_propose_ack_ping_for_lost_reply,
188b54a134aSDavid Howells 	rxrpc_propose_ack_ping_for_params,
189b54a134aSDavid Howells 	rxrpc_propose_ack_processing_op,
190b54a134aSDavid Howells 	rxrpc_propose_ack_respond_to_ack,
191b54a134aSDavid Howells 	rxrpc_propose_ack_respond_to_ping,
192b54a134aSDavid Howells 	rxrpc_propose_ack_retry_tx,
193b54a134aSDavid Howells 	rxrpc_propose_ack_rotate_rx,
194b54a134aSDavid Howells 	rxrpc_propose_ack_terminal_ack,
195b54a134aSDavid Howells };
196b54a134aSDavid Howells 
197b54a134aSDavid Howells enum rxrpc_propose_ack_outcome {
198b54a134aSDavid Howells 	rxrpc_propose_ack_subsume,
199b54a134aSDavid Howells 	rxrpc_propose_ack_update,
200b54a134aSDavid Howells 	rxrpc_propose_ack_use,
201b54a134aSDavid Howells };
202b54a134aSDavid Howells 
203b54a134aSDavid Howells enum rxrpc_congest_change {
204b54a134aSDavid Howells 	rxrpc_cong_begin_retransmission,
205b54a134aSDavid Howells 	rxrpc_cong_cleared_nacks,
206b54a134aSDavid Howells 	rxrpc_cong_new_low_nack,
207b54a134aSDavid Howells 	rxrpc_cong_no_change,
208b54a134aSDavid Howells 	rxrpc_cong_progress,
209b54a134aSDavid Howells 	rxrpc_cong_retransmit_again,
210b54a134aSDavid Howells 	rxrpc_cong_rtt_window_end,
211b54a134aSDavid Howells 	rxrpc_cong_saw_nack,
212b54a134aSDavid Howells };
213b54a134aSDavid Howells 
214b54a134aSDavid Howells #endif /* end __RXRPC_DECLARE_TRACE_ENUMS_ONCE_ONLY */
215b54a134aSDavid Howells 
216b54a134aSDavid Howells /*
217b54a134aSDavid Howells  * Declare tracing information enums and their string mappings for display.
218b54a134aSDavid Howells  */
219b54a134aSDavid Howells #define rxrpc_skb_traces \
220b54a134aSDavid Howells 	EM(rxrpc_skb_rx_cleaned,		"Rx CLN") \
221b54a134aSDavid Howells 	EM(rxrpc_skb_rx_freed,			"Rx FRE") \
222b54a134aSDavid Howells 	EM(rxrpc_skb_rx_got,			"Rx GOT") \
223b54a134aSDavid Howells 	EM(rxrpc_skb_rx_lost,			"Rx *L*") \
224b54a134aSDavid Howells 	EM(rxrpc_skb_rx_purged,			"Rx PUR") \
225b54a134aSDavid Howells 	EM(rxrpc_skb_rx_received,		"Rx RCV") \
226b54a134aSDavid Howells 	EM(rxrpc_skb_rx_rotated,		"Rx ROT") \
227b54a134aSDavid Howells 	EM(rxrpc_skb_rx_seen,			"Rx SEE") \
228b54a134aSDavid Howells 	EM(rxrpc_skb_tx_cleaned,		"Tx CLN") \
229b54a134aSDavid Howells 	EM(rxrpc_skb_tx_freed,			"Tx FRE") \
230b54a134aSDavid Howells 	EM(rxrpc_skb_tx_got,			"Tx GOT") \
231b54a134aSDavid Howells 	EM(rxrpc_skb_tx_new,			"Tx NEW") \
232b54a134aSDavid Howells 	EM(rxrpc_skb_tx_rotated,		"Tx ROT") \
233b54a134aSDavid Howells 	E_(rxrpc_skb_tx_seen,			"Tx SEE")
234b54a134aSDavid Howells 
23509d2bf59SDavid Howells #define rxrpc_local_traces \
23609d2bf59SDavid Howells 	EM(rxrpc_local_got,			"GOT") \
23709d2bf59SDavid Howells 	EM(rxrpc_local_new,			"NEW") \
23809d2bf59SDavid Howells 	EM(rxrpc_local_processing,		"PRO") \
23909d2bf59SDavid Howells 	EM(rxrpc_local_put,			"PUT") \
24009d2bf59SDavid Howells 	E_(rxrpc_local_queued,			"QUE")
24109d2bf59SDavid Howells 
2421159d4b4SDavid Howells #define rxrpc_peer_traces \
2431159d4b4SDavid Howells 	EM(rxrpc_peer_got,			"GOT") \
2441159d4b4SDavid Howells 	EM(rxrpc_peer_new,			"NEW") \
2451159d4b4SDavid Howells 	EM(rxrpc_peer_processing,		"PRO") \
2461159d4b4SDavid Howells 	EM(rxrpc_peer_put,			"PUT") \
2471159d4b4SDavid Howells 	E_(rxrpc_peer_queued_error,		"QER")
2481159d4b4SDavid Howells 
249b54a134aSDavid Howells #define rxrpc_conn_traces \
250b54a134aSDavid Howells 	EM(rxrpc_conn_got,			"GOT") \
251b54a134aSDavid Howells 	EM(rxrpc_conn_new_client,		"NWc") \
252b54a134aSDavid Howells 	EM(rxrpc_conn_new_service,		"NWs") \
253b54a134aSDavid Howells 	EM(rxrpc_conn_put_client,		"PTc") \
254b54a134aSDavid Howells 	EM(rxrpc_conn_put_service,		"PTs") \
255b54a134aSDavid Howells 	EM(rxrpc_conn_queued,			"QUE") \
256f859ab61SDavid Howells 	EM(rxrpc_conn_reap_service,		"RPs") \
257b54a134aSDavid Howells 	E_(rxrpc_conn_seen,			"SEE")
258b54a134aSDavid Howells 
259b54a134aSDavid Howells #define rxrpc_client_traces \
260b54a134aSDavid Howells 	EM(rxrpc_client_activate_chans,		"Activa") \
261b54a134aSDavid Howells 	EM(rxrpc_client_alloc,			"Alloc ") \
262b54a134aSDavid Howells 	EM(rxrpc_client_chan_activate,		"ChActv") \
263b54a134aSDavid Howells 	EM(rxrpc_client_chan_disconnect,	"ChDisc") \
264b54a134aSDavid Howells 	EM(rxrpc_client_chan_pass,		"ChPass") \
265b54a134aSDavid Howells 	EM(rxrpc_client_chan_unstarted,		"ChUnst") \
266b54a134aSDavid Howells 	EM(rxrpc_client_cleanup,		"Clean ") \
267b54a134aSDavid Howells 	EM(rxrpc_client_count,			"Count ") \
268b54a134aSDavid Howells 	EM(rxrpc_client_discard,		"Discar") \
269b54a134aSDavid Howells 	EM(rxrpc_client_duplicate,		"Duplic") \
270b54a134aSDavid Howells 	EM(rxrpc_client_exposed,		"Expose") \
271b54a134aSDavid Howells 	EM(rxrpc_client_replace,		"Replac") \
272b54a134aSDavid Howells 	EM(rxrpc_client_to_active,		"->Actv") \
273b54a134aSDavid Howells 	EM(rxrpc_client_to_culled,		"->Cull") \
274b54a134aSDavid Howells 	EM(rxrpc_client_to_idle,		"->Idle") \
275b54a134aSDavid Howells 	EM(rxrpc_client_to_inactive,		"->Inac") \
276b54a134aSDavid Howells 	EM(rxrpc_client_to_upgrade,		"->Upgd") \
277b54a134aSDavid Howells 	EM(rxrpc_client_to_waiting,		"->Wait") \
278b54a134aSDavid Howells 	E_(rxrpc_client_uncount,		"Uncoun")
279b54a134aSDavid Howells 
280b54a134aSDavid Howells #define rxrpc_conn_cache_states \
281b54a134aSDavid Howells 	EM(RXRPC_CONN_CLIENT_INACTIVE,		"Inac") \
282b54a134aSDavid Howells 	EM(RXRPC_CONN_CLIENT_WAITING,		"Wait") \
283b54a134aSDavid Howells 	EM(RXRPC_CONN_CLIENT_ACTIVE,		"Actv") \
2844e255721SDavid Howells 	EM(RXRPC_CONN_CLIENT_UPGRADE,		"Upgd") \
285b54a134aSDavid Howells 	EM(RXRPC_CONN_CLIENT_CULLED,		"Cull") \
286b54a134aSDavid Howells 	E_(RXRPC_CONN_CLIENT_IDLE,		"Idle") \
287b54a134aSDavid Howells 
288b54a134aSDavid Howells #define rxrpc_call_traces \
289b54a134aSDavid Howells 	EM(rxrpc_call_connected,		"CON") \
290b54a134aSDavid Howells 	EM(rxrpc_call_error,			"*E*") \
291b54a134aSDavid Howells 	EM(rxrpc_call_got,			"GOT") \
292b54a134aSDavid Howells 	EM(rxrpc_call_got_kernel,		"Gke") \
293b54a134aSDavid Howells 	EM(rxrpc_call_got_userid,		"Gus") \
294b54a134aSDavid Howells 	EM(rxrpc_call_new_client,		"NWc") \
295b54a134aSDavid Howells 	EM(rxrpc_call_new_service,		"NWs") \
296b54a134aSDavid Howells 	EM(rxrpc_call_put,			"PUT") \
297b54a134aSDavid Howells 	EM(rxrpc_call_put_kernel,		"Pke") \
298b54a134aSDavid Howells 	EM(rxrpc_call_put_noqueue,		"PNQ") \
299b54a134aSDavid Howells 	EM(rxrpc_call_put_userid,		"Pus") \
300b54a134aSDavid Howells 	EM(rxrpc_call_queued,			"QUE") \
301b54a134aSDavid Howells 	EM(rxrpc_call_queued_ref,		"QUR") \
302b54a134aSDavid Howells 	EM(rxrpc_call_release,			"RLS") \
303b54a134aSDavid Howells 	E_(rxrpc_call_seen,			"SEE")
304b54a134aSDavid Howells 
305b54a134aSDavid Howells #define rxrpc_transmit_traces \
306b54a134aSDavid Howells 	EM(rxrpc_transmit_await_reply,		"AWR") \
307b54a134aSDavid Howells 	EM(rxrpc_transmit_end,			"END") \
308b54a134aSDavid Howells 	EM(rxrpc_transmit_queue,		"QUE") \
309b54a134aSDavid Howells 	EM(rxrpc_transmit_queue_last,		"QLS") \
310b54a134aSDavid Howells 	EM(rxrpc_transmit_rotate,		"ROT") \
311b54a134aSDavid Howells 	EM(rxrpc_transmit_rotate_last,		"RLS") \
312b54a134aSDavid Howells 	E_(rxrpc_transmit_wait,			"WAI")
313b54a134aSDavid Howells 
314b54a134aSDavid Howells #define rxrpc_receive_traces \
315b54a134aSDavid Howells 	EM(rxrpc_receive_end,			"END") \
316b54a134aSDavid Howells 	EM(rxrpc_receive_front,			"FRN") \
317b54a134aSDavid Howells 	EM(rxrpc_receive_incoming,		"INC") \
318b54a134aSDavid Howells 	EM(rxrpc_receive_queue,			"QUE") \
319b54a134aSDavid Howells 	EM(rxrpc_receive_queue_last,		"QLS") \
320b54a134aSDavid Howells 	E_(rxrpc_receive_rotate,		"ROT")
321b54a134aSDavid Howells 
322b54a134aSDavid Howells #define rxrpc_recvmsg_traces \
323b54a134aSDavid Howells 	EM(rxrpc_recvmsg_cont,			"CONT") \
324b54a134aSDavid Howells 	EM(rxrpc_recvmsg_data_return,		"DATA") \
325b54a134aSDavid Howells 	EM(rxrpc_recvmsg_dequeue,		"DEQU") \
326b54a134aSDavid Howells 	EM(rxrpc_recvmsg_enter,			"ENTR") \
327b54a134aSDavid Howells 	EM(rxrpc_recvmsg_full,			"FULL") \
328b54a134aSDavid Howells 	EM(rxrpc_recvmsg_hole,			"HOLE") \
329b54a134aSDavid Howells 	EM(rxrpc_recvmsg_next,			"NEXT") \
330540b1c48SDavid Howells 	EM(rxrpc_recvmsg_requeue,		"REQU") \
331b54a134aSDavid Howells 	EM(rxrpc_recvmsg_return,		"RETN") \
332b54a134aSDavid Howells 	EM(rxrpc_recvmsg_terminal,		"TERM") \
333b54a134aSDavid Howells 	EM(rxrpc_recvmsg_to_be_accepted,	"TBAC") \
334b54a134aSDavid Howells 	E_(rxrpc_recvmsg_wait,			"WAIT")
335b54a134aSDavid Howells 
336b54a134aSDavid Howells #define rxrpc_rtt_tx_traces \
337b54a134aSDavid Howells 	EM(rxrpc_rtt_tx_data,			"DATA") \
338b54a134aSDavid Howells 	E_(rxrpc_rtt_tx_ping,			"PING")
339b54a134aSDavid Howells 
340b54a134aSDavid Howells #define rxrpc_rtt_rx_traces \
341b54a134aSDavid Howells 	EM(rxrpc_rtt_rx_ping_response,		"PONG") \
342b54a134aSDavid Howells 	E_(rxrpc_rtt_rx_requested_ack,		"RACK")
343b54a134aSDavid Howells 
344b54a134aSDavid Howells #define rxrpc_timer_traces \
345b54a134aSDavid Howells 	EM(rxrpc_timer_begin,			"Begin ") \
346b54a134aSDavid Howells 	EM(rxrpc_timer_expired,			"*EXPR*") \
347a158bdd3SDavid Howells 	EM(rxrpc_timer_exp_ack,			"ExpAck") \
348a158bdd3SDavid Howells 	EM(rxrpc_timer_exp_hard,		"ExpHrd") \
349a158bdd3SDavid Howells 	EM(rxrpc_timer_exp_idle,		"ExpIdl") \
350415f44e4SDavid Howells 	EM(rxrpc_timer_exp_keepalive,		"ExpKA ") \
351bd1fdf8cSDavid Howells 	EM(rxrpc_timer_exp_lost_ack,		"ExpLoA") \
352a158bdd3SDavid Howells 	EM(rxrpc_timer_exp_normal,		"ExpNml") \
353a158bdd3SDavid Howells 	EM(rxrpc_timer_exp_ping,		"ExpPng") \
354a158bdd3SDavid Howells 	EM(rxrpc_timer_exp_resend,		"ExpRsn") \
355b54a134aSDavid Howells 	EM(rxrpc_timer_init_for_reply,		"IniRpl") \
356b54a134aSDavid Howells 	EM(rxrpc_timer_init_for_send_reply,	"SndRpl") \
357a158bdd3SDavid Howells 	EM(rxrpc_timer_restart,			"Restrt") \
358b54a134aSDavid Howells 	EM(rxrpc_timer_set_for_ack,		"SetAck") \
359a158bdd3SDavid Howells 	EM(rxrpc_timer_set_for_hard,		"SetHrd") \
360a158bdd3SDavid Howells 	EM(rxrpc_timer_set_for_idle,		"SetIdl") \
361415f44e4SDavid Howells 	EM(rxrpc_timer_set_for_keepalive,	"KeepAl") \
362bd1fdf8cSDavid Howells 	EM(rxrpc_timer_set_for_lost_ack,	"SetLoA") \
363a158bdd3SDavid Howells 	EM(rxrpc_timer_set_for_normal,		"SetNml") \
364b54a134aSDavid Howells 	EM(rxrpc_timer_set_for_ping,		"SetPng") \
365b54a134aSDavid Howells 	EM(rxrpc_timer_set_for_resend,		"SetRTx") \
366a158bdd3SDavid Howells 	E_(rxrpc_timer_set_for_send,		"SetSnd")
367b54a134aSDavid Howells 
368b54a134aSDavid Howells #define rxrpc_propose_ack_traces \
369b54a134aSDavid Howells 	EM(rxrpc_propose_ack_client_tx_end,	"ClTxEnd") \
370b54a134aSDavid Howells 	EM(rxrpc_propose_ack_input_data,	"DataIn ") \
371415f44e4SDavid Howells 	EM(rxrpc_propose_ack_ping_for_keepalive, "KeepAlv") \
372b54a134aSDavid Howells 	EM(rxrpc_propose_ack_ping_for_lost_ack,	"LostAck") \
373b54a134aSDavid Howells 	EM(rxrpc_propose_ack_ping_for_lost_reply, "LostRpl") \
374b54a134aSDavid Howells 	EM(rxrpc_propose_ack_ping_for_params,	"Params ") \
375b54a134aSDavid Howells 	EM(rxrpc_propose_ack_processing_op,	"ProcOp ") \
376b54a134aSDavid Howells 	EM(rxrpc_propose_ack_respond_to_ack,	"Rsp2Ack") \
377b54a134aSDavid Howells 	EM(rxrpc_propose_ack_respond_to_ping,	"Rsp2Png") \
378b54a134aSDavid Howells 	EM(rxrpc_propose_ack_retry_tx,		"RetryTx") \
379b54a134aSDavid Howells 	EM(rxrpc_propose_ack_rotate_rx,		"RxAck  ") \
380b54a134aSDavid Howells 	E_(rxrpc_propose_ack_terminal_ack,	"ClTerm ")
381b54a134aSDavid Howells 
382b54a134aSDavid Howells #define rxrpc_propose_ack_outcomes \
383b54a134aSDavid Howells 	EM(rxrpc_propose_ack_subsume,		" Subsume") \
384b54a134aSDavid Howells 	EM(rxrpc_propose_ack_update,		" Update") \
385b54a134aSDavid Howells 	E_(rxrpc_propose_ack_use,		"")
386b54a134aSDavid Howells 
387b54a134aSDavid Howells #define rxrpc_congest_modes \
388b54a134aSDavid Howells 	EM(RXRPC_CALL_CONGEST_AVOIDANCE,	"CongAvoid") \
389b54a134aSDavid Howells 	EM(RXRPC_CALL_FAST_RETRANSMIT,		"FastReTx ") \
390b54a134aSDavid Howells 	EM(RXRPC_CALL_PACKET_LOSS,		"PktLoss  ") \
391b54a134aSDavid Howells 	E_(RXRPC_CALL_SLOW_START,		"SlowStart")
392b54a134aSDavid Howells 
393b54a134aSDavid Howells #define rxrpc_congest_changes \
394b54a134aSDavid Howells 	EM(rxrpc_cong_begin_retransmission,	" Retrans") \
395b54a134aSDavid Howells 	EM(rxrpc_cong_cleared_nacks,		" Cleared") \
396b54a134aSDavid Howells 	EM(rxrpc_cong_new_low_nack,		" NewLowN") \
397b54a134aSDavid Howells 	EM(rxrpc_cong_no_change,		"") \
398b54a134aSDavid Howells 	EM(rxrpc_cong_progress,			" Progres") \
399b54a134aSDavid Howells 	EM(rxrpc_cong_retransmit_again,		" ReTxAgn") \
400b54a134aSDavid Howells 	EM(rxrpc_cong_rtt_window_end,		" RttWinE") \
401b54a134aSDavid Howells 	E_(rxrpc_cong_saw_nack,			" SawNack")
402b54a134aSDavid Howells 
403b54a134aSDavid Howells #define rxrpc_pkts \
404b54a134aSDavid Howells 	EM(0,					"?00") \
405b54a134aSDavid Howells 	EM(RXRPC_PACKET_TYPE_DATA,		"DATA") \
406b54a134aSDavid Howells 	EM(RXRPC_PACKET_TYPE_ACK,		"ACK") \
407b54a134aSDavid Howells 	EM(RXRPC_PACKET_TYPE_BUSY,		"BUSY") \
408b54a134aSDavid Howells 	EM(RXRPC_PACKET_TYPE_ABORT,		"ABORT") \
409b54a134aSDavid Howells 	EM(RXRPC_PACKET_TYPE_ACKALL,		"ACKALL") \
410b54a134aSDavid Howells 	EM(RXRPC_PACKET_TYPE_CHALLENGE,		"CHALL") \
411b54a134aSDavid Howells 	EM(RXRPC_PACKET_TYPE_RESPONSE,		"RESP") \
412b54a134aSDavid Howells 	EM(RXRPC_PACKET_TYPE_DEBUG,		"DEBUG") \
413b54a134aSDavid Howells 	EM(9,					"?09") \
414b54a134aSDavid Howells 	EM(10,					"?10") \
415b54a134aSDavid Howells 	EM(11,					"?11") \
416b54a134aSDavid Howells 	EM(12,					"?12") \
417b54a134aSDavid Howells 	EM(RXRPC_PACKET_TYPE_VERSION,		"VERSION") \
418b54a134aSDavid Howells 	EM(14,					"?14") \
419b54a134aSDavid Howells 	E_(15,					"?15")
420b54a134aSDavid Howells 
421b54a134aSDavid Howells #define rxrpc_ack_names \
422b54a134aSDavid Howells 	EM(0,					"-0-") \
423b54a134aSDavid Howells 	EM(RXRPC_ACK_REQUESTED,			"REQ") \
424b54a134aSDavid Howells 	EM(RXRPC_ACK_DUPLICATE,			"DUP") \
425b54a134aSDavid Howells 	EM(RXRPC_ACK_OUT_OF_SEQUENCE,		"OOS") \
426b54a134aSDavid Howells 	EM(RXRPC_ACK_EXCEEDS_WINDOW,		"WIN") \
427b54a134aSDavid Howells 	EM(RXRPC_ACK_NOSPACE,			"MEM") \
428b54a134aSDavid Howells 	EM(RXRPC_ACK_PING,			"PNG") \
429b54a134aSDavid Howells 	EM(RXRPC_ACK_PING_RESPONSE,		"PNR") \
430b54a134aSDavid Howells 	EM(RXRPC_ACK_DELAY,			"DLY") \
431b54a134aSDavid Howells 	EM(RXRPC_ACK_IDLE,			"IDL") \
432b54a134aSDavid Howells 	E_(RXRPC_ACK__INVALID,			"-?-")
433b54a134aSDavid Howells 
4341bae5d22SDavid Howells #define rxrpc_completions \
4351bae5d22SDavid Howells 	EM(RXRPC_CALL_SUCCEEDED,		"Succeeded") \
4361bae5d22SDavid Howells 	EM(RXRPC_CALL_REMOTELY_ABORTED,		"RemoteAbort") \
4371bae5d22SDavid Howells 	EM(RXRPC_CALL_LOCALLY_ABORTED,		"LocalAbort") \
4381bae5d22SDavid Howells 	EM(RXRPC_CALL_LOCAL_ERROR,		"LocalError") \
4391bae5d22SDavid Howells 	E_(RXRPC_CALL_NETWORK_ERROR,		"NetError")
4401bae5d22SDavid Howells 
441b54a134aSDavid Howells /*
442b54a134aSDavid Howells  * Export enum symbols via userspace.
443b54a134aSDavid Howells  */
444b54a134aSDavid Howells #undef EM
445b54a134aSDavid Howells #undef E_
446b54a134aSDavid Howells #define EM(a, b) TRACE_DEFINE_ENUM(a);
447b54a134aSDavid Howells #define E_(a, b) TRACE_DEFINE_ENUM(a);
448b54a134aSDavid Howells 
449b54a134aSDavid Howells rxrpc_skb_traces;
45009d2bf59SDavid Howells rxrpc_local_traces;
451b54a134aSDavid Howells rxrpc_conn_traces;
452b54a134aSDavid Howells rxrpc_client_traces;
453b54a134aSDavid Howells rxrpc_call_traces;
454b54a134aSDavid Howells rxrpc_transmit_traces;
455b54a134aSDavid Howells rxrpc_receive_traces;
456b54a134aSDavid Howells rxrpc_recvmsg_traces;
457b54a134aSDavid Howells rxrpc_rtt_tx_traces;
458b54a134aSDavid Howells rxrpc_rtt_rx_traces;
459b54a134aSDavid Howells rxrpc_timer_traces;
460b54a134aSDavid Howells rxrpc_propose_ack_traces;
461b54a134aSDavid Howells rxrpc_propose_ack_outcomes;
462827efed6SDavid Howells rxrpc_congest_modes;
463b54a134aSDavid Howells rxrpc_congest_changes;
464b54a134aSDavid Howells 
465b54a134aSDavid Howells /*
466b54a134aSDavid Howells  * Now redefine the EM() and E_() macros to map the enums to the strings that
467b54a134aSDavid Howells  * will be printed in the output.
468b54a134aSDavid Howells  */
469b54a134aSDavid Howells #undef EM
470b54a134aSDavid Howells #undef E_
471b54a134aSDavid Howells #define EM(a, b)	{ a, b },
472b54a134aSDavid Howells #define E_(a, b)	{ a, b }
473b54a134aSDavid Howells 
47409d2bf59SDavid Howells TRACE_EVENT(rxrpc_local,
47509d2bf59SDavid Howells 	    TP_PROTO(struct rxrpc_local *local, enum rxrpc_local_trace op,
47609d2bf59SDavid Howells 		     int usage, const void *where),
47709d2bf59SDavid Howells 
47809d2bf59SDavid Howells 	    TP_ARGS(local, op, usage, where),
47909d2bf59SDavid Howells 
48009d2bf59SDavid Howells 	    TP_STRUCT__entry(
48109d2bf59SDavid Howells 		    __field(unsigned int,	local		)
48209d2bf59SDavid Howells 		    __field(int,		op		)
48309d2bf59SDavid Howells 		    __field(int,		usage		)
48409d2bf59SDavid Howells 		    __field(const void *,	where		)
48509d2bf59SDavid Howells 			     ),
48609d2bf59SDavid Howells 
48709d2bf59SDavid Howells 	    TP_fast_assign(
48809d2bf59SDavid Howells 		    __entry->local = local->debug_id;
48909d2bf59SDavid Howells 		    __entry->op = op;
49009d2bf59SDavid Howells 		    __entry->usage = usage;
49109d2bf59SDavid Howells 		    __entry->where = where;
49209d2bf59SDavid Howells 			   ),
49309d2bf59SDavid Howells 
49409d2bf59SDavid Howells 	    TP_printk("L=%08x %s u=%d sp=%pSR",
49509d2bf59SDavid Howells 		      __entry->local,
49609d2bf59SDavid Howells 		      __print_symbolic(__entry->op, rxrpc_local_traces),
49709d2bf59SDavid Howells 		      __entry->usage,
49809d2bf59SDavid Howells 		      __entry->where)
49909d2bf59SDavid Howells 	    );
50009d2bf59SDavid Howells 
5011159d4b4SDavid Howells TRACE_EVENT(rxrpc_peer,
5021159d4b4SDavid Howells 	    TP_PROTO(struct rxrpc_peer *peer, enum rxrpc_peer_trace op,
5031159d4b4SDavid Howells 		     int usage, const void *where),
5041159d4b4SDavid Howells 
5051159d4b4SDavid Howells 	    TP_ARGS(peer, op, usage, where),
5061159d4b4SDavid Howells 
5071159d4b4SDavid Howells 	    TP_STRUCT__entry(
5081159d4b4SDavid Howells 		    __field(unsigned int,	peer		)
5091159d4b4SDavid Howells 		    __field(int,		op		)
5101159d4b4SDavid Howells 		    __field(int,		usage		)
5111159d4b4SDavid Howells 		    __field(const void *,	where		)
5121159d4b4SDavid Howells 			     ),
5131159d4b4SDavid Howells 
5141159d4b4SDavid Howells 	    TP_fast_assign(
5151159d4b4SDavid Howells 		    __entry->peer = peer->debug_id;
5161159d4b4SDavid Howells 		    __entry->op = op;
5171159d4b4SDavid Howells 		    __entry->usage = usage;
5181159d4b4SDavid Howells 		    __entry->where = where;
5191159d4b4SDavid Howells 			   ),
5201159d4b4SDavid Howells 
5211159d4b4SDavid Howells 	    TP_printk("P=%08x %s u=%d sp=%pSR",
5221159d4b4SDavid Howells 		      __entry->peer,
5231159d4b4SDavid Howells 		      __print_symbolic(__entry->op, rxrpc_peer_traces),
5241159d4b4SDavid Howells 		      __entry->usage,
5251159d4b4SDavid Howells 		      __entry->where)
5261159d4b4SDavid Howells 	    );
5271159d4b4SDavid Howells 
528363deeabSDavid Howells TRACE_EVENT(rxrpc_conn,
529363deeabSDavid Howells 	    TP_PROTO(struct rxrpc_connection *conn, enum rxrpc_conn_trace op,
530363deeabSDavid Howells 		     int usage, const void *where),
531363deeabSDavid Howells 
532363deeabSDavid Howells 	    TP_ARGS(conn, op, usage, where),
533363deeabSDavid Howells 
534363deeabSDavid Howells 	    TP_STRUCT__entry(
535a25e21f0SDavid Howells 		    __field(unsigned int,	conn		)
536363deeabSDavid Howells 		    __field(int,		op		)
537363deeabSDavid Howells 		    __field(int,		usage		)
538363deeabSDavid Howells 		    __field(const void *,	where		)
539363deeabSDavid Howells 			     ),
540363deeabSDavid Howells 
541363deeabSDavid Howells 	    TP_fast_assign(
542a25e21f0SDavid Howells 		    __entry->conn = conn->debug_id;
543363deeabSDavid Howells 		    __entry->op = op;
544363deeabSDavid Howells 		    __entry->usage = usage;
545363deeabSDavid Howells 		    __entry->where = where;
546363deeabSDavid Howells 			   ),
547363deeabSDavid Howells 
548a25e21f0SDavid Howells 	    TP_printk("C=%08x %s u=%d sp=%pSR",
549363deeabSDavid Howells 		      __entry->conn,
550b54a134aSDavid Howells 		      __print_symbolic(__entry->op, rxrpc_conn_traces),
551363deeabSDavid Howells 		      __entry->usage,
552363deeabSDavid Howells 		      __entry->where)
553363deeabSDavid Howells 	    );
554363deeabSDavid Howells 
555363deeabSDavid Howells TRACE_EVENT(rxrpc_client,
556363deeabSDavid Howells 	    TP_PROTO(struct rxrpc_connection *conn, int channel,
557363deeabSDavid Howells 		     enum rxrpc_client_trace op),
558363deeabSDavid Howells 
559363deeabSDavid Howells 	    TP_ARGS(conn, channel, op),
560363deeabSDavid Howells 
561363deeabSDavid Howells 	    TP_STRUCT__entry(
562a25e21f0SDavid Howells 		    __field(unsigned int,		conn		)
563363deeabSDavid Howells 		    __field(u32,			cid		)
564363deeabSDavid Howells 		    __field(int,			channel		)
565363deeabSDavid Howells 		    __field(int,			usage		)
566363deeabSDavid Howells 		    __field(enum rxrpc_client_trace,	op		)
567363deeabSDavid Howells 		    __field(enum rxrpc_conn_cache_state, cs		)
568363deeabSDavid Howells 			     ),
569363deeabSDavid Howells 
570363deeabSDavid Howells 	    TP_fast_assign(
571a25e21f0SDavid Howells 		    __entry->conn = conn->debug_id;
572363deeabSDavid Howells 		    __entry->channel = channel;
573363deeabSDavid Howells 		    __entry->usage = atomic_read(&conn->usage);
574363deeabSDavid Howells 		    __entry->op = op;
575363deeabSDavid Howells 		    __entry->cid = conn->proto.cid;
576363deeabSDavid Howells 		    __entry->cs = conn->cache_state;
577363deeabSDavid Howells 			   ),
578363deeabSDavid Howells 
579a25e21f0SDavid Howells 	    TP_printk("C=%08x h=%2d %s %s i=%08x u=%d",
580363deeabSDavid Howells 		      __entry->conn,
581363deeabSDavid Howells 		      __entry->channel,
582b54a134aSDavid Howells 		      __print_symbolic(__entry->op, rxrpc_client_traces),
583b54a134aSDavid Howells 		      __print_symbolic(__entry->cs, rxrpc_conn_cache_states),
584363deeabSDavid Howells 		      __entry->cid,
585363deeabSDavid Howells 		      __entry->usage)
586363deeabSDavid Howells 	    );
587363deeabSDavid Howells 
588e34d4234SDavid Howells TRACE_EVENT(rxrpc_call,
589fff72429SDavid Howells 	    TP_PROTO(struct rxrpc_call *call, enum rxrpc_call_trace op,
5902ab27215SDavid Howells 		     int usage, const void *where, const void *aux),
591e34d4234SDavid Howells 
5922ab27215SDavid Howells 	    TP_ARGS(call, op, usage, where, aux),
593e34d4234SDavid Howells 
594e34d4234SDavid Howells 	    TP_STRUCT__entry(
595a25e21f0SDavid Howells 		    __field(unsigned int,		call		)
596e34d4234SDavid Howells 		    __field(int,			op		)
597e34d4234SDavid Howells 		    __field(int,			usage		)
598e34d4234SDavid Howells 		    __field(const void *,		where		)
599e34d4234SDavid Howells 		    __field(const void *,		aux		)
600e34d4234SDavid Howells 			     ),
601e34d4234SDavid Howells 
602e34d4234SDavid Howells 	    TP_fast_assign(
603a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
604e34d4234SDavid Howells 		    __entry->op = op;
605e34d4234SDavid Howells 		    __entry->usage = usage;
606e34d4234SDavid Howells 		    __entry->where = where;
607e34d4234SDavid Howells 		    __entry->aux = aux;
608e34d4234SDavid Howells 			   ),
609e34d4234SDavid Howells 
610a25e21f0SDavid Howells 	    TP_printk("c=%08x %s u=%d sp=%pSR a=%p",
611e34d4234SDavid Howells 		      __entry->call,
612b54a134aSDavid Howells 		      __print_symbolic(__entry->op, rxrpc_call_traces),
613e34d4234SDavid Howells 		      __entry->usage,
614e34d4234SDavid Howells 		      __entry->where,
615e34d4234SDavid Howells 		      __entry->aux)
616e34d4234SDavid Howells 	    );
617e34d4234SDavid Howells 
618df844fd4SDavid Howells TRACE_EVENT(rxrpc_skb,
61971f3ca40SDavid Howells 	    TP_PROTO(struct sk_buff *skb, enum rxrpc_skb_trace op,
62071f3ca40SDavid Howells 		     int usage, int mod_count, const void *where),
621df844fd4SDavid Howells 
622df844fd4SDavid Howells 	    TP_ARGS(skb, op, usage, mod_count, where),
623df844fd4SDavid Howells 
624df844fd4SDavid Howells 	    TP_STRUCT__entry(
625df844fd4SDavid Howells 		    __field(struct sk_buff *,		skb		)
62671f3ca40SDavid Howells 		    __field(enum rxrpc_skb_trace,	op		)
627df844fd4SDavid Howells 		    __field(int,			usage		)
628df844fd4SDavid Howells 		    __field(int,			mod_count	)
629df844fd4SDavid Howells 		    __field(const void *,		where		)
630df844fd4SDavid Howells 			     ),
631df844fd4SDavid Howells 
632df844fd4SDavid Howells 	    TP_fast_assign(
633df844fd4SDavid Howells 		    __entry->skb = skb;
634df844fd4SDavid Howells 		    __entry->op = op;
635df844fd4SDavid Howells 		    __entry->usage = usage;
636df844fd4SDavid Howells 		    __entry->mod_count = mod_count;
637df844fd4SDavid Howells 		    __entry->where = where;
638df844fd4SDavid Howells 			   ),
639df844fd4SDavid Howells 
640df844fd4SDavid Howells 	    TP_printk("s=%p %s u=%d m=%d p=%pSR",
641df844fd4SDavid Howells 		      __entry->skb,
642b54a134aSDavid Howells 		      __print_symbolic(__entry->op, rxrpc_skb_traces),
643df844fd4SDavid Howells 		      __entry->usage,
644df844fd4SDavid Howells 		      __entry->mod_count,
645df844fd4SDavid Howells 		      __entry->where)
646df844fd4SDavid Howells 	    );
647df844fd4SDavid Howells 
64849e19ec7SDavid Howells TRACE_EVENT(rxrpc_rx_packet,
64949e19ec7SDavid Howells 	    TP_PROTO(struct rxrpc_skb_priv *sp),
65049e19ec7SDavid Howells 
65149e19ec7SDavid Howells 	    TP_ARGS(sp),
65249e19ec7SDavid Howells 
65349e19ec7SDavid Howells 	    TP_STRUCT__entry(
65449e19ec7SDavid Howells 		    __field_struct(struct rxrpc_host_header,	hdr		)
65549e19ec7SDavid Howells 			     ),
65649e19ec7SDavid Howells 
65749e19ec7SDavid Howells 	    TP_fast_assign(
65849e19ec7SDavid Howells 		    memcpy(&__entry->hdr, &sp->hdr, sizeof(__entry->hdr));
65949e19ec7SDavid Howells 			   ),
66049e19ec7SDavid Howells 
661a3868bfcSDavid Howells 	    TP_printk("%08x:%08x:%08x:%04x %08x %08x %02x %02x %s",
66249e19ec7SDavid Howells 		      __entry->hdr.epoch, __entry->hdr.cid,
66349e19ec7SDavid Howells 		      __entry->hdr.callNumber, __entry->hdr.serviceId,
66449e19ec7SDavid Howells 		      __entry->hdr.serial, __entry->hdr.seq,
665a3868bfcSDavid Howells 		      __entry->hdr.type, __entry->hdr.flags,
666b54a134aSDavid Howells 		      __entry->hdr.type <= 15 ?
667b54a134aSDavid Howells 		      __print_symbolic(__entry->hdr.type, rxrpc_pkts) : "?UNK")
66849e19ec7SDavid Howells 	    );
66949e19ec7SDavid Howells 
67049e19ec7SDavid Howells TRACE_EVENT(rxrpc_rx_done,
67149e19ec7SDavid Howells 	    TP_PROTO(int result, int abort_code),
67249e19ec7SDavid Howells 
67349e19ec7SDavid Howells 	    TP_ARGS(result, abort_code),
67449e19ec7SDavid Howells 
67549e19ec7SDavid Howells 	    TP_STRUCT__entry(
67649e19ec7SDavid Howells 		    __field(int,			result		)
67749e19ec7SDavid Howells 		    __field(int,			abort_code	)
67849e19ec7SDavid Howells 			     ),
67949e19ec7SDavid Howells 
68049e19ec7SDavid Howells 	    TP_fast_assign(
68149e19ec7SDavid Howells 		    __entry->result = result;
68249e19ec7SDavid Howells 		    __entry->abort_code = abort_code;
68349e19ec7SDavid Howells 			   ),
68449e19ec7SDavid Howells 
68549e19ec7SDavid Howells 	    TP_printk("r=%d a=%d", __entry->result, __entry->abort_code)
68649e19ec7SDavid Howells 	    );
68749e19ec7SDavid Howells 
6885a42976dSDavid Howells TRACE_EVENT(rxrpc_abort,
689a25e21f0SDavid Howells 	    TP_PROTO(unsigned int call_nr, const char *why, u32 cid, u32 call_id,
690a25e21f0SDavid Howells 		     rxrpc_seq_t seq, int abort_code, int error),
6915a42976dSDavid Howells 
692a25e21f0SDavid Howells 	    TP_ARGS(call_nr, why, cid, call_id, seq, abort_code, error),
6935a42976dSDavid Howells 
6945a42976dSDavid Howells 	    TP_STRUCT__entry(
695a25e21f0SDavid Howells 		    __field(unsigned int,		call_nr		)
6965a42976dSDavid Howells 		    __array(char,			why, 4		)
6975a42976dSDavid Howells 		    __field(u32,			cid		)
6985a42976dSDavid Howells 		    __field(u32,			call_id		)
6995a42976dSDavid Howells 		    __field(rxrpc_seq_t,		seq		)
7005a42976dSDavid Howells 		    __field(int,			abort_code	)
7015a42976dSDavid Howells 		    __field(int,			error		)
7025a42976dSDavid Howells 			     ),
7035a42976dSDavid Howells 
7045a42976dSDavid Howells 	    TP_fast_assign(
7055a42976dSDavid Howells 		    memcpy(__entry->why, why, 4);
706a25e21f0SDavid Howells 		    __entry->call_nr = call_nr;
7075a42976dSDavid Howells 		    __entry->cid = cid;
7085a42976dSDavid Howells 		    __entry->call_id = call_id;
7095a42976dSDavid Howells 		    __entry->abort_code = abort_code;
7105a42976dSDavid Howells 		    __entry->error = error;
7115a42976dSDavid Howells 		    __entry->seq = seq;
7125a42976dSDavid Howells 			   ),
7135a42976dSDavid Howells 
714a25e21f0SDavid Howells 	    TP_printk("c=%08x %08x:%08x s=%u a=%d e=%d %s",
715a25e21f0SDavid Howells 		      __entry->call_nr,
7165a42976dSDavid Howells 		      __entry->cid, __entry->call_id, __entry->seq,
7175a42976dSDavid Howells 		      __entry->abort_code, __entry->error, __entry->why)
7185a42976dSDavid Howells 	    );
7195a42976dSDavid Howells 
7201bae5d22SDavid Howells TRACE_EVENT(rxrpc_call_complete,
7211bae5d22SDavid Howells 	    TP_PROTO(struct rxrpc_call *call),
7221bae5d22SDavid Howells 
7231bae5d22SDavid Howells 	    TP_ARGS(call),
7241bae5d22SDavid Howells 
7251bae5d22SDavid Howells 	    TP_STRUCT__entry(
7261bae5d22SDavid Howells 		    __field(unsigned int,		call		)
7271bae5d22SDavid Howells 		    __field(enum rxrpc_call_completion,	compl		)
7281bae5d22SDavid Howells 		    __field(int,			error		)
7291bae5d22SDavid Howells 		    __field(u32,			abort_code	)
7301bae5d22SDavid Howells 			     ),
7311bae5d22SDavid Howells 
7321bae5d22SDavid Howells 	    TP_fast_assign(
7331bae5d22SDavid Howells 		    __entry->call = call->debug_id;
7341bae5d22SDavid Howells 		    __entry->compl = call->completion;
7351bae5d22SDavid Howells 		    __entry->error = call->error;
7361bae5d22SDavid Howells 		    __entry->abort_code = call->abort_code;
7371bae5d22SDavid Howells 			   ),
7381bae5d22SDavid Howells 
7391bae5d22SDavid Howells 	    TP_printk("c=%08x %s r=%d ac=%d",
7401bae5d22SDavid Howells 		      __entry->call,
7411bae5d22SDavid Howells 		      __print_symbolic(__entry->compl, rxrpc_completions),
7421bae5d22SDavid Howells 		      __entry->error,
7431bae5d22SDavid Howells 		      __entry->abort_code)
7441bae5d22SDavid Howells 	    );
7451bae5d22SDavid Howells 
746a124fe3eSDavid Howells TRACE_EVENT(rxrpc_transmit,
747a124fe3eSDavid Howells 	    TP_PROTO(struct rxrpc_call *call, enum rxrpc_transmit_trace why),
748a124fe3eSDavid Howells 
749a124fe3eSDavid Howells 	    TP_ARGS(call, why),
750a124fe3eSDavid Howells 
751a124fe3eSDavid Howells 	    TP_STRUCT__entry(
752a25e21f0SDavid Howells 		    __field(unsigned int,		call		)
753a124fe3eSDavid Howells 		    __field(enum rxrpc_transmit_trace,	why		)
754a124fe3eSDavid Howells 		    __field(rxrpc_seq_t,		tx_hard_ack	)
755a124fe3eSDavid Howells 		    __field(rxrpc_seq_t,		tx_top		)
756b1d9f7fdSDavid Howells 		    __field(int,			tx_winsize	)
757a124fe3eSDavid Howells 			     ),
758a124fe3eSDavid Howells 
759a124fe3eSDavid Howells 	    TP_fast_assign(
760a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
761a124fe3eSDavid Howells 		    __entry->why = why;
762a124fe3eSDavid Howells 		    __entry->tx_hard_ack = call->tx_hard_ack;
763a124fe3eSDavid Howells 		    __entry->tx_top = call->tx_top;
764b1d9f7fdSDavid Howells 		    __entry->tx_winsize = call->tx_winsize;
765a124fe3eSDavid Howells 			   ),
766a124fe3eSDavid Howells 
767a25e21f0SDavid Howells 	    TP_printk("c=%08x %s f=%08x n=%u/%u",
768a124fe3eSDavid Howells 		      __entry->call,
769b54a134aSDavid Howells 		      __print_symbolic(__entry->why, rxrpc_transmit_traces),
770a124fe3eSDavid Howells 		      __entry->tx_hard_ack + 1,
771b1d9f7fdSDavid Howells 		      __entry->tx_top - __entry->tx_hard_ack,
772b1d9f7fdSDavid Howells 		      __entry->tx_winsize)
773a124fe3eSDavid Howells 	    );
774a124fe3eSDavid Howells 
775b1d9f7fdSDavid Howells TRACE_EVENT(rxrpc_rx_data,
776b1d9f7fdSDavid Howells 	    TP_PROTO(struct rxrpc_call *call, rxrpc_seq_t seq,
777b1d9f7fdSDavid Howells 		     rxrpc_serial_t serial, u8 flags, u8 anno),
778ec71eb9aSDavid Howells 
779b1d9f7fdSDavid Howells 	    TP_ARGS(call, seq, serial, flags, anno),
780ec71eb9aSDavid Howells 
781ec71eb9aSDavid Howells 	    TP_STRUCT__entry(
782a25e21f0SDavid Howells 		    __field(unsigned int,		call		)
783b1d9f7fdSDavid Howells 		    __field(rxrpc_seq_t,		seq		)
784b1d9f7fdSDavid Howells 		    __field(rxrpc_serial_t,		serial		)
785b1d9f7fdSDavid Howells 		    __field(u8,				flags		)
786b1d9f7fdSDavid Howells 		    __field(u8,				anno		)
787b1d9f7fdSDavid Howells 			     ),
788b1d9f7fdSDavid Howells 
789b1d9f7fdSDavid Howells 	    TP_fast_assign(
790a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
791b1d9f7fdSDavid Howells 		    __entry->seq = seq;
792b1d9f7fdSDavid Howells 		    __entry->serial = serial;
793b1d9f7fdSDavid Howells 		    __entry->flags = flags;
794b1d9f7fdSDavid Howells 		    __entry->anno = anno;
795b1d9f7fdSDavid Howells 			   ),
796b1d9f7fdSDavid Howells 
797a25e21f0SDavid Howells 	    TP_printk("c=%08x DATA %08x q=%08x fl=%02x a=%02x",
798b1d9f7fdSDavid Howells 		      __entry->call,
799b1d9f7fdSDavid Howells 		      __entry->serial,
800b1d9f7fdSDavid Howells 		      __entry->seq,
801b1d9f7fdSDavid Howells 		      __entry->flags,
802b1d9f7fdSDavid Howells 		      __entry->anno)
803b1d9f7fdSDavid Howells 	    );
804b1d9f7fdSDavid Howells 
805b1d9f7fdSDavid Howells TRACE_EVENT(rxrpc_rx_ack,
806b1d9f7fdSDavid Howells 	    TP_PROTO(struct rxrpc_call *call,
807b1d9f7fdSDavid Howells 		     rxrpc_serial_t serial, rxrpc_serial_t ack_serial,
808b1d9f7fdSDavid Howells 		     rxrpc_seq_t first, rxrpc_seq_t prev, u8 reason, u8 n_acks),
809b1d9f7fdSDavid Howells 
810b1d9f7fdSDavid Howells 	    TP_ARGS(call, serial, ack_serial, first, prev, reason, n_acks),
811b1d9f7fdSDavid Howells 
812b1d9f7fdSDavid Howells 	    TP_STRUCT__entry(
813a25e21f0SDavid Howells 		    __field(unsigned int,		call		)
814b1d9f7fdSDavid Howells 		    __field(rxrpc_serial_t,		serial		)
815b1d9f7fdSDavid Howells 		    __field(rxrpc_serial_t,		ack_serial	)
816ec71eb9aSDavid Howells 		    __field(rxrpc_seq_t,		first		)
817b1d9f7fdSDavid Howells 		    __field(rxrpc_seq_t,		prev		)
818ec71eb9aSDavid Howells 		    __field(u8,				reason		)
819ec71eb9aSDavid Howells 		    __field(u8,				n_acks		)
820ec71eb9aSDavid Howells 			     ),
821ec71eb9aSDavid Howells 
822ec71eb9aSDavid Howells 	    TP_fast_assign(
823a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
824b1d9f7fdSDavid Howells 		    __entry->serial = serial;
825b1d9f7fdSDavid Howells 		    __entry->ack_serial = ack_serial;
826ec71eb9aSDavid Howells 		    __entry->first = first;
827b1d9f7fdSDavid Howells 		    __entry->prev = prev;
828ec71eb9aSDavid Howells 		    __entry->reason = reason;
829ec71eb9aSDavid Howells 		    __entry->n_acks = n_acks;
830ec71eb9aSDavid Howells 			   ),
831ec71eb9aSDavid Howells 
832a25e21f0SDavid Howells 	    TP_printk("c=%08x %08x %s r=%08x f=%08x p=%08x n=%u",
833ec71eb9aSDavid Howells 		      __entry->call,
834b1d9f7fdSDavid Howells 		      __entry->serial,
835b54a134aSDavid Howells 		      __print_symbolic(__entry->reason, rxrpc_ack_names),
836b1d9f7fdSDavid Howells 		      __entry->ack_serial,
837ec71eb9aSDavid Howells 		      __entry->first,
838b1d9f7fdSDavid Howells 		      __entry->prev,
839ec71eb9aSDavid Howells 		      __entry->n_acks)
840ec71eb9aSDavid Howells 	    );
841ec71eb9aSDavid Howells 
842005ede28SDavid Howells TRACE_EVENT(rxrpc_rx_abort,
843005ede28SDavid Howells 	    TP_PROTO(struct rxrpc_call *call, rxrpc_serial_t serial,
844005ede28SDavid Howells 		     u32 abort_code),
845005ede28SDavid Howells 
846005ede28SDavid Howells 	    TP_ARGS(call, serial, abort_code),
847005ede28SDavid Howells 
848005ede28SDavid Howells 	    TP_STRUCT__entry(
849a25e21f0SDavid Howells 		    __field(unsigned int,		call		)
850005ede28SDavid Howells 		    __field(rxrpc_serial_t,		serial		)
851005ede28SDavid Howells 		    __field(u32,			abort_code	)
852005ede28SDavid Howells 			     ),
853005ede28SDavid Howells 
854005ede28SDavid Howells 	    TP_fast_assign(
855a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
856005ede28SDavid Howells 		    __entry->serial = serial;
857005ede28SDavid Howells 		    __entry->abort_code = abort_code;
858005ede28SDavid Howells 			   ),
859005ede28SDavid Howells 
860a25e21f0SDavid Howells 	    TP_printk("c=%08x ABORT %08x ac=%d",
861005ede28SDavid Howells 		      __entry->call,
862005ede28SDavid Howells 		      __entry->serial,
863005ede28SDavid Howells 		      __entry->abort_code)
864005ede28SDavid Howells 	    );
865005ede28SDavid Howells 
866740586d2SDavid Howells TRACE_EVENT(rxrpc_rx_rwind_change,
867740586d2SDavid Howells 	    TP_PROTO(struct rxrpc_call *call, rxrpc_serial_t serial,
868740586d2SDavid Howells 		     u32 rwind, bool wake),
869740586d2SDavid Howells 
870740586d2SDavid Howells 	    TP_ARGS(call, serial, rwind, wake),
871740586d2SDavid Howells 
872740586d2SDavid Howells 	    TP_STRUCT__entry(
873a25e21f0SDavid Howells 		    __field(unsigned int,		call		)
874740586d2SDavid Howells 		    __field(rxrpc_serial_t,		serial		)
875740586d2SDavid Howells 		    __field(u32,			rwind		)
876740586d2SDavid Howells 		    __field(bool,			wake		)
877740586d2SDavid Howells 			     ),
878740586d2SDavid Howells 
879740586d2SDavid Howells 	    TP_fast_assign(
880a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
881740586d2SDavid Howells 		    __entry->serial = serial;
882740586d2SDavid Howells 		    __entry->rwind = rwind;
883740586d2SDavid Howells 		    __entry->wake = wake;
884740586d2SDavid Howells 			   ),
885740586d2SDavid Howells 
886a25e21f0SDavid Howells 	    TP_printk("c=%08x %08x rw=%u%s",
887740586d2SDavid Howells 		      __entry->call,
888740586d2SDavid Howells 		      __entry->serial,
889740586d2SDavid Howells 		      __entry->rwind,
890740586d2SDavid Howells 		      __entry->wake ? " wake" : "")
891740586d2SDavid Howells 	    );
892740586d2SDavid Howells 
893be832aecSDavid Howells TRACE_EVENT(rxrpc_tx_data,
894be832aecSDavid Howells 	    TP_PROTO(struct rxrpc_call *call, rxrpc_seq_t seq,
895a1767077SDavid Howells 		     rxrpc_serial_t serial, u8 flags, bool retrans, bool lose),
896f3639df2SDavid Howells 
897a1767077SDavid Howells 	    TP_ARGS(call, seq, serial, flags, retrans, lose),
898f3639df2SDavid Howells 
899f3639df2SDavid Howells 	    TP_STRUCT__entry(
900a25e21f0SDavid Howells 		    __field(unsigned int,		call		)
901be832aecSDavid Howells 		    __field(rxrpc_seq_t,		seq		)
902f3639df2SDavid Howells 		    __field(rxrpc_serial_t,		serial		)
903be832aecSDavid Howells 		    __field(u8,				flags		)
904a1767077SDavid Howells 		    __field(bool,			retrans		)
905be832aecSDavid Howells 		    __field(bool,			lose		)
906be832aecSDavid Howells 			     ),
907be832aecSDavid Howells 
908be832aecSDavid Howells 	    TP_fast_assign(
909a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
910be832aecSDavid Howells 		    __entry->seq = seq;
911be832aecSDavid Howells 		    __entry->serial = serial;
912be832aecSDavid Howells 		    __entry->flags = flags;
913a1767077SDavid Howells 		    __entry->retrans = retrans;
914be832aecSDavid Howells 		    __entry->lose = lose;
915be832aecSDavid Howells 			   ),
916be832aecSDavid Howells 
917a25e21f0SDavid Howells 	    TP_printk("c=%08x DATA %08x q=%08x fl=%02x%s%s",
918be832aecSDavid Howells 		      __entry->call,
919be832aecSDavid Howells 		      __entry->serial,
920be832aecSDavid Howells 		      __entry->seq,
921be832aecSDavid Howells 		      __entry->flags,
922265a44bbSDavid Howells 		      __entry->retrans ? " *RETRANS*" : "",
923be832aecSDavid Howells 		      __entry->lose ? " *LOSE*" : "")
924be832aecSDavid Howells 	    );
925be832aecSDavid Howells 
926be832aecSDavid Howells TRACE_EVENT(rxrpc_tx_ack,
927be832aecSDavid Howells 	    TP_PROTO(struct rxrpc_call *call, rxrpc_serial_t serial,
928be832aecSDavid Howells 		     rxrpc_seq_t ack_first, rxrpc_serial_t ack_serial,
929be832aecSDavid Howells 		     u8 reason, u8 n_acks),
930be832aecSDavid Howells 
931be832aecSDavid Howells 	    TP_ARGS(call, serial, ack_first, ack_serial, reason, n_acks),
932be832aecSDavid Howells 
933be832aecSDavid Howells 	    TP_STRUCT__entry(
934a25e21f0SDavid Howells 		    __field(unsigned int,		call		)
935be832aecSDavid Howells 		    __field(rxrpc_serial_t,		serial		)
936be832aecSDavid Howells 		    __field(rxrpc_seq_t,		ack_first	)
937be832aecSDavid Howells 		    __field(rxrpc_serial_t,		ack_serial	)
938f3639df2SDavid Howells 		    __field(u8,				reason		)
939f3639df2SDavid Howells 		    __field(u8,				n_acks		)
940f3639df2SDavid Howells 			     ),
941f3639df2SDavid Howells 
942f3639df2SDavid Howells 	    TP_fast_assign(
943a25e21f0SDavid Howells 		    __entry->call = call ? call->debug_id : 0;
944f3639df2SDavid Howells 		    __entry->serial = serial;
945be832aecSDavid Howells 		    __entry->ack_first = ack_first;
946be832aecSDavid Howells 		    __entry->ack_serial = ack_serial;
947f3639df2SDavid Howells 		    __entry->reason = reason;
948f3639df2SDavid Howells 		    __entry->n_acks = n_acks;
949f3639df2SDavid Howells 			   ),
950f3639df2SDavid Howells 
951a25e21f0SDavid Howells 	    TP_printk(" c=%08x ACK  %08x %s f=%08x r=%08x n=%u",
952f3639df2SDavid Howells 		      __entry->call,
953f3639df2SDavid Howells 		      __entry->serial,
954b54a134aSDavid Howells 		      __print_symbolic(__entry->reason, rxrpc_ack_names),
955be832aecSDavid Howells 		      __entry->ack_first,
956be832aecSDavid Howells 		      __entry->ack_serial,
957f3639df2SDavid Howells 		      __entry->n_acks)
958f3639df2SDavid Howells 	    );
959f3639df2SDavid Howells 
96058dc63c9SDavid Howells TRACE_EVENT(rxrpc_receive,
96158dc63c9SDavid Howells 	    TP_PROTO(struct rxrpc_call *call, enum rxrpc_receive_trace why,
96258dc63c9SDavid Howells 		     rxrpc_serial_t serial, rxrpc_seq_t seq),
96358dc63c9SDavid Howells 
96458dc63c9SDavid Howells 	    TP_ARGS(call, why, serial, seq),
96558dc63c9SDavid Howells 
96658dc63c9SDavid Howells 	    TP_STRUCT__entry(
967a25e21f0SDavid Howells 		    __field(unsigned int,		call		)
96858dc63c9SDavid Howells 		    __field(enum rxrpc_receive_trace,	why		)
96958dc63c9SDavid Howells 		    __field(rxrpc_serial_t,		serial		)
97058dc63c9SDavid Howells 		    __field(rxrpc_seq_t,		seq		)
97158dc63c9SDavid Howells 		    __field(rxrpc_seq_t,		hard_ack	)
97258dc63c9SDavid Howells 		    __field(rxrpc_seq_t,		top		)
97358dc63c9SDavid Howells 			     ),
97458dc63c9SDavid Howells 
97558dc63c9SDavid Howells 	    TP_fast_assign(
976a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
97758dc63c9SDavid Howells 		    __entry->why = why;
97858dc63c9SDavid Howells 		    __entry->serial = serial;
97958dc63c9SDavid Howells 		    __entry->seq = seq;
98058dc63c9SDavid Howells 		    __entry->hard_ack = call->rx_hard_ack;
98158dc63c9SDavid Howells 		    __entry->top = call->rx_top;
98258dc63c9SDavid Howells 			   ),
98358dc63c9SDavid Howells 
984a25e21f0SDavid Howells 	    TP_printk("c=%08x %s r=%08x q=%08x w=%08x-%08x",
98558dc63c9SDavid Howells 		      __entry->call,
986b54a134aSDavid Howells 		      __print_symbolic(__entry->why, rxrpc_receive_traces),
98758dc63c9SDavid Howells 		      __entry->serial,
98858dc63c9SDavid Howells 		      __entry->seq,
98958dc63c9SDavid Howells 		      __entry->hard_ack,
99058dc63c9SDavid Howells 		      __entry->top)
99158dc63c9SDavid Howells 	    );
99258dc63c9SDavid Howells 
99384997905SDavid Howells TRACE_EVENT(rxrpc_recvmsg,
99484997905SDavid Howells 	    TP_PROTO(struct rxrpc_call *call, enum rxrpc_recvmsg_trace why,
99584997905SDavid Howells 		     rxrpc_seq_t seq, unsigned int offset, unsigned int len,
99684997905SDavid Howells 		     int ret),
99784997905SDavid Howells 
99884997905SDavid Howells 	    TP_ARGS(call, why, seq, offset, len, ret),
99984997905SDavid Howells 
100084997905SDavid Howells 	    TP_STRUCT__entry(
1001a25e21f0SDavid Howells 		    __field(unsigned int,		call		)
100284997905SDavid Howells 		    __field(enum rxrpc_recvmsg_trace,	why		)
100384997905SDavid Howells 		    __field(rxrpc_seq_t,		seq		)
100484997905SDavid Howells 		    __field(unsigned int,		offset		)
100584997905SDavid Howells 		    __field(unsigned int,		len		)
100684997905SDavid Howells 		    __field(int,			ret		)
100784997905SDavid Howells 			     ),
100884997905SDavid Howells 
100984997905SDavid Howells 	    TP_fast_assign(
1010a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
101184997905SDavid Howells 		    __entry->why = why;
101284997905SDavid Howells 		    __entry->seq = seq;
101384997905SDavid Howells 		    __entry->offset = offset;
101484997905SDavid Howells 		    __entry->len = len;
101584997905SDavid Howells 		    __entry->ret = ret;
101684997905SDavid Howells 			   ),
101784997905SDavid Howells 
1018a25e21f0SDavid Howells 	    TP_printk("c=%08x %s q=%08x o=%u l=%u ret=%d",
101984997905SDavid Howells 		      __entry->call,
1020b54a134aSDavid Howells 		      __print_symbolic(__entry->why, rxrpc_recvmsg_traces),
102184997905SDavid Howells 		      __entry->seq,
102284997905SDavid Howells 		      __entry->offset,
102384997905SDavid Howells 		      __entry->len,
102484997905SDavid Howells 		      __entry->ret)
102584997905SDavid Howells 	    );
102684997905SDavid Howells 
1027cf1a6474SDavid Howells TRACE_EVENT(rxrpc_rtt_tx,
1028cf1a6474SDavid Howells 	    TP_PROTO(struct rxrpc_call *call, enum rxrpc_rtt_tx_trace why,
1029cf1a6474SDavid Howells 		     rxrpc_serial_t send_serial),
1030cf1a6474SDavid Howells 
1031cf1a6474SDavid Howells 	    TP_ARGS(call, why, send_serial),
1032cf1a6474SDavid Howells 
1033cf1a6474SDavid Howells 	    TP_STRUCT__entry(
1034a25e21f0SDavid Howells 		    __field(unsigned int,		call		)
1035cf1a6474SDavid Howells 		    __field(enum rxrpc_rtt_tx_trace,	why		)
1036cf1a6474SDavid Howells 		    __field(rxrpc_serial_t,		send_serial	)
1037cf1a6474SDavid Howells 			     ),
1038cf1a6474SDavid Howells 
1039cf1a6474SDavid Howells 	    TP_fast_assign(
1040a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
1041cf1a6474SDavid Howells 		    __entry->why = why;
1042cf1a6474SDavid Howells 		    __entry->send_serial = send_serial;
1043cf1a6474SDavid Howells 			   ),
1044cf1a6474SDavid Howells 
1045a25e21f0SDavid Howells 	    TP_printk("c=%08x %s sr=%08x",
1046cf1a6474SDavid Howells 		      __entry->call,
1047b54a134aSDavid Howells 		      __print_symbolic(__entry->why, rxrpc_rtt_tx_traces),
1048cf1a6474SDavid Howells 		      __entry->send_serial)
1049cf1a6474SDavid Howells 	    );
1050cf1a6474SDavid Howells 
1051cf1a6474SDavid Howells TRACE_EVENT(rxrpc_rtt_rx,
1052cf1a6474SDavid Howells 	    TP_PROTO(struct rxrpc_call *call, enum rxrpc_rtt_rx_trace why,
1053cf1a6474SDavid Howells 		     rxrpc_serial_t send_serial, rxrpc_serial_t resp_serial,
1054cf1a6474SDavid Howells 		     s64 rtt, u8 nr, s64 avg),
1055cf1a6474SDavid Howells 
1056cf1a6474SDavid Howells 	    TP_ARGS(call, why, send_serial, resp_serial, rtt, nr, avg),
1057cf1a6474SDavid Howells 
1058cf1a6474SDavid Howells 	    TP_STRUCT__entry(
1059a25e21f0SDavid Howells 		    __field(unsigned int,		call		)
1060cf1a6474SDavid Howells 		    __field(enum rxrpc_rtt_rx_trace,	why		)
1061cf1a6474SDavid Howells 		    __field(u8,				nr		)
1062cf1a6474SDavid Howells 		    __field(rxrpc_serial_t,		send_serial	)
1063cf1a6474SDavid Howells 		    __field(rxrpc_serial_t,		resp_serial	)
1064cf1a6474SDavid Howells 		    __field(s64,			rtt		)
1065cf1a6474SDavid Howells 		    __field(u64,			avg		)
1066cf1a6474SDavid Howells 			     ),
1067cf1a6474SDavid Howells 
1068cf1a6474SDavid Howells 	    TP_fast_assign(
1069a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
1070cf1a6474SDavid Howells 		    __entry->why = why;
1071cf1a6474SDavid Howells 		    __entry->send_serial = send_serial;
1072cf1a6474SDavid Howells 		    __entry->resp_serial = resp_serial;
1073cf1a6474SDavid Howells 		    __entry->rtt = rtt;
1074cf1a6474SDavid Howells 		    __entry->nr = nr;
1075cf1a6474SDavid Howells 		    __entry->avg = avg;
1076cf1a6474SDavid Howells 			   ),
1077cf1a6474SDavid Howells 
1078a25e21f0SDavid Howells 	    TP_printk("c=%08x %s sr=%08x rr=%08x rtt=%lld nr=%u avg=%lld",
1079cf1a6474SDavid Howells 		      __entry->call,
1080b54a134aSDavid Howells 		      __print_symbolic(__entry->why, rxrpc_rtt_rx_traces),
1081cf1a6474SDavid Howells 		      __entry->send_serial,
1082cf1a6474SDavid Howells 		      __entry->resp_serial,
1083cf1a6474SDavid Howells 		      __entry->rtt,
1084cf1a6474SDavid Howells 		      __entry->nr,
1085cf1a6474SDavid Howells 		      __entry->avg)
1086cf1a6474SDavid Howells 	    );
1087cf1a6474SDavid Howells 
1088fc7ab6d2SDavid Howells TRACE_EVENT(rxrpc_timer,
1089fc7ab6d2SDavid Howells 	    TP_PROTO(struct rxrpc_call *call, enum rxrpc_timer_trace why,
1090a158bdd3SDavid Howells 		     unsigned long now),
1091fc7ab6d2SDavid Howells 
1092a158bdd3SDavid Howells 	    TP_ARGS(call, why, now),
1093fc7ab6d2SDavid Howells 
1094fc7ab6d2SDavid Howells 	    TP_STRUCT__entry(
1095a25e21f0SDavid Howells 		    __field(unsigned int,			call		)
1096fc7ab6d2SDavid Howells 		    __field(enum rxrpc_timer_trace,		why		)
1097a158bdd3SDavid Howells 		    __field(long,				now		)
1098a158bdd3SDavid Howells 		    __field(long,				ack_at		)
1099bd1fdf8cSDavid Howells 		    __field(long,				ack_lost_at	)
1100a158bdd3SDavid Howells 		    __field(long,				resend_at	)
1101a158bdd3SDavid Howells 		    __field(long,				ping_at		)
1102a158bdd3SDavid Howells 		    __field(long,				expect_rx_by	)
1103a158bdd3SDavid Howells 		    __field(long,				expect_req_by	)
1104a158bdd3SDavid Howells 		    __field(long,				expect_term_by	)
1105a158bdd3SDavid Howells 		    __field(long,				timer		)
1106fc7ab6d2SDavid Howells 			     ),
1107fc7ab6d2SDavid Howells 
1108fc7ab6d2SDavid Howells 	    TP_fast_assign(
1109a25e21f0SDavid Howells 		    __entry->call		= call->debug_id;
1110fc7ab6d2SDavid Howells 		    __entry->why		= why;
1111fc7ab6d2SDavid Howells 		    __entry->now		= now;
1112fc7ab6d2SDavid Howells 		    __entry->ack_at		= call->ack_at;
1113bd1fdf8cSDavid Howells 		    __entry->ack_lost_at	= call->ack_lost_at;
1114fc7ab6d2SDavid Howells 		    __entry->resend_at		= call->resend_at;
1115a158bdd3SDavid Howells 		    __entry->expect_rx_by	= call->expect_rx_by;
1116a158bdd3SDavid Howells 		    __entry->expect_req_by	= call->expect_req_by;
1117a158bdd3SDavid Howells 		    __entry->expect_term_by	= call->expect_term_by;
1118fc7ab6d2SDavid Howells 		    __entry->timer		= call->timer.expires;
1119fc7ab6d2SDavid Howells 			   ),
1120fc7ab6d2SDavid Howells 
1121a25e21f0SDavid Howells 	    TP_printk("c=%08x %s a=%ld la=%ld r=%ld xr=%ld xq=%ld xt=%ld t=%ld",
1122fc7ab6d2SDavid Howells 		      __entry->call,
1123b54a134aSDavid Howells 		      __print_symbolic(__entry->why, rxrpc_timer_traces),
1124a158bdd3SDavid Howells 		      __entry->ack_at - __entry->now,
1125bd1fdf8cSDavid Howells 		      __entry->ack_lost_at - __entry->now,
1126a158bdd3SDavid Howells 		      __entry->resend_at - __entry->now,
1127a158bdd3SDavid Howells 		      __entry->expect_rx_by - __entry->now,
1128a158bdd3SDavid Howells 		      __entry->expect_req_by - __entry->now,
1129a158bdd3SDavid Howells 		      __entry->expect_term_by - __entry->now,
1130a158bdd3SDavid Howells 		      __entry->timer - __entry->now)
1131fc7ab6d2SDavid Howells 	    );
1132fc7ab6d2SDavid Howells 
113389b475abSDavid Howells TRACE_EVENT(rxrpc_rx_lose,
113489b475abSDavid Howells 	    TP_PROTO(struct rxrpc_skb_priv *sp),
113589b475abSDavid Howells 
113689b475abSDavid Howells 	    TP_ARGS(sp),
113789b475abSDavid Howells 
113889b475abSDavid Howells 	    TP_STRUCT__entry(
113989b475abSDavid Howells 		    __field_struct(struct rxrpc_host_header,	hdr		)
114089b475abSDavid Howells 			     ),
114189b475abSDavid Howells 
114289b475abSDavid Howells 	    TP_fast_assign(
114389b475abSDavid Howells 		    memcpy(&__entry->hdr, &sp->hdr, sizeof(__entry->hdr));
114489b475abSDavid Howells 			   ),
114589b475abSDavid Howells 
114689b475abSDavid Howells 	    TP_printk("%08x:%08x:%08x:%04x %08x %08x %02x %02x %s *LOSE*",
114789b475abSDavid Howells 		      __entry->hdr.epoch, __entry->hdr.cid,
114889b475abSDavid Howells 		      __entry->hdr.callNumber, __entry->hdr.serviceId,
114989b475abSDavid Howells 		      __entry->hdr.serial, __entry->hdr.seq,
115089b475abSDavid Howells 		      __entry->hdr.type, __entry->hdr.flags,
1151b54a134aSDavid Howells 		      __entry->hdr.type <= 15 ?
1152b54a134aSDavid Howells 		      __print_symbolic(__entry->hdr.type, rxrpc_pkts) : "?UNK")
115389b475abSDavid Howells 	    );
115489b475abSDavid Howells 
11559c7ad434SDavid Howells TRACE_EVENT(rxrpc_propose_ack,
11569c7ad434SDavid Howells 	    TP_PROTO(struct rxrpc_call *call, enum rxrpc_propose_ack_trace why,
11579c7ad434SDavid Howells 		     u8 ack_reason, rxrpc_serial_t serial, bool immediate,
11589c7ad434SDavid Howells 		     bool background, enum rxrpc_propose_ack_outcome outcome),
11599c7ad434SDavid Howells 
11609c7ad434SDavid Howells 	    TP_ARGS(call, why, ack_reason, serial, immediate, background,
11619c7ad434SDavid Howells 		    outcome),
11629c7ad434SDavid Howells 
11639c7ad434SDavid Howells 	    TP_STRUCT__entry(
1164a25e21f0SDavid Howells 		    __field(unsigned int,			call		)
11659c7ad434SDavid Howells 		    __field(enum rxrpc_propose_ack_trace,	why		)
11669c7ad434SDavid Howells 		    __field(rxrpc_serial_t,			serial		)
11679c7ad434SDavid Howells 		    __field(u8,					ack_reason	)
11689c7ad434SDavid Howells 		    __field(bool,				immediate	)
11699c7ad434SDavid Howells 		    __field(bool,				background	)
11709c7ad434SDavid Howells 		    __field(enum rxrpc_propose_ack_outcome,	outcome		)
11719c7ad434SDavid Howells 			     ),
11729c7ad434SDavid Howells 
11739c7ad434SDavid Howells 	    TP_fast_assign(
1174a25e21f0SDavid Howells 		    __entry->call	= call->debug_id;
11759c7ad434SDavid Howells 		    __entry->why	= why;
11769c7ad434SDavid Howells 		    __entry->serial	= serial;
11779c7ad434SDavid Howells 		    __entry->ack_reason	= ack_reason;
11789c7ad434SDavid Howells 		    __entry->immediate	= immediate;
11799c7ad434SDavid Howells 		    __entry->background	= background;
11809c7ad434SDavid Howells 		    __entry->outcome	= outcome;
11819c7ad434SDavid Howells 			   ),
11829c7ad434SDavid Howells 
1183a25e21f0SDavid Howells 	    TP_printk("c=%08x %s %s r=%08x i=%u b=%u%s",
11849c7ad434SDavid Howells 		      __entry->call,
1185b54a134aSDavid Howells 		      __print_symbolic(__entry->why, rxrpc_propose_ack_traces),
1186b54a134aSDavid Howells 		      __print_symbolic(__entry->ack_reason, rxrpc_ack_names),
11879c7ad434SDavid Howells 		      __entry->serial,
11889c7ad434SDavid Howells 		      __entry->immediate,
11899c7ad434SDavid Howells 		      __entry->background,
1190b54a134aSDavid Howells 		      __print_symbolic(__entry->outcome, rxrpc_propose_ack_outcomes))
11919c7ad434SDavid Howells 	    );
11929c7ad434SDavid Howells 
1193c6672e3fSDavid Howells TRACE_EVENT(rxrpc_retransmit,
1194c6672e3fSDavid Howells 	    TP_PROTO(struct rxrpc_call *call, rxrpc_seq_t seq, u8 annotation,
1195c6672e3fSDavid Howells 		     s64 expiry),
1196c6672e3fSDavid Howells 
1197c6672e3fSDavid Howells 	    TP_ARGS(call, seq, annotation, expiry),
1198c6672e3fSDavid Howells 
1199c6672e3fSDavid Howells 	    TP_STRUCT__entry(
1200a25e21f0SDavid Howells 		    __field(unsigned int,		call		)
1201c6672e3fSDavid Howells 		    __field(rxrpc_seq_t,		seq		)
1202c6672e3fSDavid Howells 		    __field(u8,				annotation	)
1203c6672e3fSDavid Howells 		    __field(s64,			expiry		)
1204c6672e3fSDavid Howells 			     ),
1205c6672e3fSDavid Howells 
1206c6672e3fSDavid Howells 	    TP_fast_assign(
1207a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
1208c6672e3fSDavid Howells 		    __entry->seq = seq;
1209c6672e3fSDavid Howells 		    __entry->annotation = annotation;
1210c6672e3fSDavid Howells 		    __entry->expiry = expiry;
1211c6672e3fSDavid Howells 			   ),
1212c6672e3fSDavid Howells 
1213a25e21f0SDavid Howells 	    TP_printk("c=%08x q=%x a=%02x xp=%lld",
1214c6672e3fSDavid Howells 		      __entry->call,
1215c6672e3fSDavid Howells 		      __entry->seq,
1216c6672e3fSDavid Howells 		      __entry->annotation,
1217c6672e3fSDavid Howells 		      __entry->expiry)
1218c6672e3fSDavid Howells 	    );
1219c6672e3fSDavid Howells 
122057494343SDavid Howells TRACE_EVENT(rxrpc_congest,
122157494343SDavid Howells 	    TP_PROTO(struct rxrpc_call *call, struct rxrpc_ack_summary *summary,
122257494343SDavid Howells 		     rxrpc_serial_t ack_serial, enum rxrpc_congest_change change),
122357494343SDavid Howells 
122457494343SDavid Howells 	    TP_ARGS(call, summary, ack_serial, change),
122557494343SDavid Howells 
122657494343SDavid Howells 	    TP_STRUCT__entry(
1227a25e21f0SDavid Howells 		    __field(unsigned int,			call		)
122857494343SDavid Howells 		    __field(enum rxrpc_congest_change,		change		)
122957494343SDavid Howells 		    __field(rxrpc_seq_t,			hard_ack	)
123057494343SDavid Howells 		    __field(rxrpc_seq_t,			top		)
123157494343SDavid Howells 		    __field(rxrpc_seq_t,			lowest_nak	)
123257494343SDavid Howells 		    __field(rxrpc_serial_t,			ack_serial	)
123357494343SDavid Howells 		    __field_struct(struct rxrpc_ack_summary,	sum		)
123457494343SDavid Howells 			     ),
123557494343SDavid Howells 
123657494343SDavid Howells 	    TP_fast_assign(
1237a25e21f0SDavid Howells 		    __entry->call	= call->debug_id;
123857494343SDavid Howells 		    __entry->change	= change;
123957494343SDavid Howells 		    __entry->hard_ack	= call->tx_hard_ack;
124057494343SDavid Howells 		    __entry->top	= call->tx_top;
124157494343SDavid Howells 		    __entry->lowest_nak	= call->acks_lowest_nak;
124257494343SDavid Howells 		    __entry->ack_serial	= ack_serial;
124357494343SDavid Howells 		    memcpy(&__entry->sum, summary, sizeof(__entry->sum));
124457494343SDavid Howells 			   ),
124557494343SDavid Howells 
1246a25e21f0SDavid Howells 	    TP_printk("c=%08x r=%08x %s q=%08x %s cw=%u ss=%u nr=%u,%u nw=%u,%u r=%u b=%u u=%u d=%u l=%x%s%s%s",
124757494343SDavid Howells 		      __entry->call,
124857494343SDavid Howells 		      __entry->ack_serial,
1249b54a134aSDavid Howells 		      __print_symbolic(__entry->sum.ack_reason, rxrpc_ack_names),
125057494343SDavid Howells 		      __entry->hard_ack,
1251b54a134aSDavid Howells 		      __print_symbolic(__entry->sum.mode, rxrpc_congest_modes),
125257494343SDavid Howells 		      __entry->sum.cwnd,
125357494343SDavid Howells 		      __entry->sum.ssthresh,
125457494343SDavid Howells 		      __entry->sum.nr_acks, __entry->sum.nr_nacks,
125557494343SDavid Howells 		      __entry->sum.nr_new_acks, __entry->sum.nr_new_nacks,
125657494343SDavid Howells 		      __entry->sum.nr_rot_new_acks,
125757494343SDavid Howells 		      __entry->top - __entry->hard_ack,
125857494343SDavid Howells 		      __entry->sum.cumulative_acks,
125957494343SDavid Howells 		      __entry->sum.dup_acks,
126057494343SDavid Howells 		      __entry->lowest_nak, __entry->sum.new_low_nack ? "!" : "",
1261b54a134aSDavid Howells 		      __print_symbolic(__entry->change, rxrpc_congest_changes),
126257494343SDavid Howells 		      __entry->sum.retrans_timeo ? " rTxTo" : "")
126357494343SDavid Howells 	    );
126457494343SDavid Howells 
1265b1d9f7fdSDavid Howells TRACE_EVENT(rxrpc_disconnect_call,
1266b1d9f7fdSDavid Howells 	    TP_PROTO(struct rxrpc_call *call),
1267b1d9f7fdSDavid Howells 
1268b1d9f7fdSDavid Howells 	    TP_ARGS(call),
1269b1d9f7fdSDavid Howells 
1270b1d9f7fdSDavid Howells 	    TP_STRUCT__entry(
1271a25e21f0SDavid Howells 		    __field(unsigned int,		call		)
1272b1d9f7fdSDavid Howells 		    __field(u32,			abort_code	)
1273b1d9f7fdSDavid Howells 			     ),
1274b1d9f7fdSDavid Howells 
1275b1d9f7fdSDavid Howells 	    TP_fast_assign(
1276a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
1277b1d9f7fdSDavid Howells 		    __entry->abort_code = call->abort_code;
1278b1d9f7fdSDavid Howells 			   ),
1279b1d9f7fdSDavid Howells 
1280a25e21f0SDavid Howells 	    TP_printk("c=%08x ab=%08x",
1281b1d9f7fdSDavid Howells 		      __entry->call,
1282b1d9f7fdSDavid Howells 		      __entry->abort_code)
1283b1d9f7fdSDavid Howells 	    );
1284b1d9f7fdSDavid Howells 
1285b1d9f7fdSDavid Howells TRACE_EVENT(rxrpc_improper_term,
1286b1d9f7fdSDavid Howells 	    TP_PROTO(struct rxrpc_call *call),
1287b1d9f7fdSDavid Howells 
1288b1d9f7fdSDavid Howells 	    TP_ARGS(call),
1289b1d9f7fdSDavid Howells 
1290b1d9f7fdSDavid Howells 	    TP_STRUCT__entry(
1291a25e21f0SDavid Howells 		    __field(unsigned int,		call		)
1292b1d9f7fdSDavid Howells 		    __field(u32,			abort_code	)
1293b1d9f7fdSDavid Howells 			     ),
1294b1d9f7fdSDavid Howells 
1295b1d9f7fdSDavid Howells 	    TP_fast_assign(
1296a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
1297b1d9f7fdSDavid Howells 		    __entry->abort_code = call->abort_code;
1298b1d9f7fdSDavid Howells 			   ),
1299b1d9f7fdSDavid Howells 
1300a25e21f0SDavid Howells 	    TP_printk("c=%08x ab=%08x",
1301b1d9f7fdSDavid Howells 		      __entry->call,
1302b1d9f7fdSDavid Howells 		      __entry->abort_code)
1303b1d9f7fdSDavid Howells 	    );
1304b1d9f7fdSDavid Howells 
1305fb46f6eeSDavid Howells TRACE_EVENT(rxrpc_rx_eproto,
1306fb46f6eeSDavid Howells 	    TP_PROTO(struct rxrpc_call *call, rxrpc_serial_t serial,
1307fb46f6eeSDavid Howells 		     const char *why),
1308fb46f6eeSDavid Howells 
1309fb46f6eeSDavid Howells 	    TP_ARGS(call, serial, why),
1310fb46f6eeSDavid Howells 
1311fb46f6eeSDavid Howells 	    TP_STRUCT__entry(
1312a25e21f0SDavid Howells 		    __field(unsigned int,		call		)
1313fb46f6eeSDavid Howells 		    __field(rxrpc_serial_t,		serial		)
1314fb46f6eeSDavid Howells 		    __field(const char *,		why		)
1315fb46f6eeSDavid Howells 			     ),
1316fb46f6eeSDavid Howells 
1317fb46f6eeSDavid Howells 	    TP_fast_assign(
1318a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
1319fb46f6eeSDavid Howells 		    __entry->serial = serial;
1320fb46f6eeSDavid Howells 		    __entry->why = why;
1321fb46f6eeSDavid Howells 			   ),
1322fb46f6eeSDavid Howells 
1323a25e21f0SDavid Howells 	    TP_printk("c=%08x EPROTO %08x %s",
1324fb46f6eeSDavid Howells 		      __entry->call,
1325fb46f6eeSDavid Howells 		      __entry->serial,
1326fb46f6eeSDavid Howells 		      __entry->why)
1327fb46f6eeSDavid Howells 	    );
1328fb46f6eeSDavid Howells 
132989ca6948SDavid Howells TRACE_EVENT(rxrpc_connect_call,
133089ca6948SDavid Howells 	    TP_PROTO(struct rxrpc_call *call),
133189ca6948SDavid Howells 
133289ca6948SDavid Howells 	    TP_ARGS(call),
133389ca6948SDavid Howells 
133489ca6948SDavid Howells 	    TP_STRUCT__entry(
1335a25e21f0SDavid Howells 		    __field(unsigned int,		call		)
133689ca6948SDavid Howells 		    __field(unsigned long,		user_call_ID	)
133789ca6948SDavid Howells 		    __field(u32,			cid		)
133889ca6948SDavid Howells 		    __field(u32,			call_id		)
133989ca6948SDavid Howells 			     ),
134089ca6948SDavid Howells 
134189ca6948SDavid Howells 	    TP_fast_assign(
1342a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
134389ca6948SDavid Howells 		    __entry->user_call_ID = call->user_call_ID;
134489ca6948SDavid Howells 		    __entry->cid = call->cid;
134589ca6948SDavid Howells 		    __entry->call_id = call->call_id;
134689ca6948SDavid Howells 			   ),
134789ca6948SDavid Howells 
1348a25e21f0SDavid Howells 	    TP_printk("c=%08x u=%p %08x:%08x",
134989ca6948SDavid Howells 		      __entry->call,
135089ca6948SDavid Howells 		      (void *)__entry->user_call_ID,
135189ca6948SDavid Howells 		      __entry->cid,
135289ca6948SDavid Howells 		      __entry->call_id)
135389ca6948SDavid Howells 	    );
135489ca6948SDavid Howells 
1355827efed6SDavid Howells TRACE_EVENT(rxrpc_resend,
1356827efed6SDavid Howells 	    TP_PROTO(struct rxrpc_call *call, int ix),
1357827efed6SDavid Howells 
1358827efed6SDavid Howells 	    TP_ARGS(call, ix),
1359827efed6SDavid Howells 
1360827efed6SDavid Howells 	    TP_STRUCT__entry(
1361a25e21f0SDavid Howells 		    __field(unsigned int,		call		)
1362827efed6SDavid Howells 		    __field(int,			ix		)
1363827efed6SDavid Howells 		    __array(u8,				anno, 64	)
1364827efed6SDavid Howells 			     ),
1365827efed6SDavid Howells 
1366827efed6SDavid Howells 	    TP_fast_assign(
1367a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
1368827efed6SDavid Howells 		    __entry->ix = ix;
1369827efed6SDavid Howells 		    memcpy(__entry->anno, call->rxtx_annotations, 64);
1370827efed6SDavid Howells 			   ),
1371827efed6SDavid Howells 
1372a25e21f0SDavid Howells 	    TP_printk("c=%08x ix=%u a=%64phN",
1373827efed6SDavid Howells 		      __entry->call,
1374827efed6SDavid Howells 		      __entry->ix,
1375827efed6SDavid Howells 		      __entry->anno)
1376827efed6SDavid Howells 	    );
1377827efed6SDavid Howells 
1378*494337c9SDavid Howells TRACE_EVENT(rxrpc_rx_icmp,
1379*494337c9SDavid Howells 	    TP_PROTO(struct rxrpc_peer *peer, struct sock_extended_err *ee,
1380*494337c9SDavid Howells 		     struct sockaddr_rxrpc *srx),
1381*494337c9SDavid Howells 
1382*494337c9SDavid Howells 	    TP_ARGS(peer, ee, srx),
1383*494337c9SDavid Howells 
1384*494337c9SDavid Howells 	    TP_STRUCT__entry(
1385*494337c9SDavid Howells 		    __field(unsigned int,			peer	)
1386*494337c9SDavid Howells 		    __field_struct(struct sock_extended_err,	ee	)
1387*494337c9SDavid Howells 		    __field_struct(struct sockaddr_rxrpc,	srx	)
1388*494337c9SDavid Howells 			     ),
1389*494337c9SDavid Howells 
1390*494337c9SDavid Howells 	    TP_fast_assign(
1391*494337c9SDavid Howells 		    __entry->peer = peer->debug_id;
1392*494337c9SDavid Howells 		    memcpy(&__entry->ee, ee, sizeof(__entry->ee));
1393*494337c9SDavid Howells 		    memcpy(&__entry->srx, srx, sizeof(__entry->srx));
1394*494337c9SDavid Howells 			   ),
1395*494337c9SDavid Howells 
1396*494337c9SDavid Howells 	    TP_printk("P=%08x o=%u t=%u c=%u i=%u d=%u e=%d %pISp",
1397*494337c9SDavid Howells 		      __entry->peer,
1398*494337c9SDavid Howells 		      __entry->ee.ee_origin,
1399*494337c9SDavid Howells 		      __entry->ee.ee_type,
1400*494337c9SDavid Howells 		      __entry->ee.ee_code,
1401*494337c9SDavid Howells 		      __entry->ee.ee_info,
1402*494337c9SDavid Howells 		      __entry->ee.ee_data,
1403*494337c9SDavid Howells 		      __entry->ee.ee_errno,
1404*494337c9SDavid Howells 		      &__entry->srx.transport)
1405*494337c9SDavid Howells 	    );
1406*494337c9SDavid Howells 
1407df844fd4SDavid Howells #endif /* _TRACE_RXRPC_H */
1408df844fd4SDavid Howells 
1409df844fd4SDavid Howells /* This part must be outside protection */
1410df844fd4SDavid Howells #include <trace/define_trace.h>
1411