xref: /openbmc/linux/include/trace/events/rxrpc.h (revision c078381856230f1e8e13738661d83c2b4b433819)
1b4d0d230SThomas Gleixner /* SPDX-License-Identifier: GPL-2.0-or-later */
2df844fd4SDavid Howells /* AF_RXRPC tracepoints
3df844fd4SDavid Howells  *
4df844fd4SDavid Howells  * Copyright (C) 2016 Red Hat, Inc. All Rights Reserved.
5df844fd4SDavid Howells  * Written by David Howells (dhowells@redhat.com)
6df844fd4SDavid Howells  */
7df844fd4SDavid Howells #undef TRACE_SYSTEM
8df844fd4SDavid Howells #define TRACE_SYSTEM rxrpc
9df844fd4SDavid Howells 
10df844fd4SDavid Howells #if !defined(_TRACE_RXRPC_H) || defined(TRACE_HEADER_MULTI_READ)
11df844fd4SDavid Howells #define _TRACE_RXRPC_H
12df844fd4SDavid Howells 
13df844fd4SDavid Howells #include <linux/tracepoint.h>
14494337c9SDavid Howells #include <linux/errqueue.h>
15df844fd4SDavid Howells 
16b54a134aSDavid Howells /*
17b54a134aSDavid Howells  * Declare tracing information enums and their string mappings for display.
18b54a134aSDavid Howells  */
1957af281eSDavid Howells #define rxrpc_abort_reasons \
2057af281eSDavid Howells 	/* AFS errors */						\
2157af281eSDavid Howells 	EM(afs_abort_general_error,		"afs-error")		\
2257af281eSDavid Howells 	EM(afs_abort_interrupted,		"afs-intr")		\
2357af281eSDavid Howells 	EM(afs_abort_oom,			"afs-oom")		\
2457af281eSDavid Howells 	EM(afs_abort_op_not_supported,		"afs-op-notsupp")	\
2557af281eSDavid Howells 	EM(afs_abort_probeuuid_negative,	"afs-probeuuid-neg")	\
2657af281eSDavid Howells 	EM(afs_abort_send_data_error,		"afs-send-data")	\
2757af281eSDavid Howells 	EM(afs_abort_unmarshal_error,		"afs-unmarshal")	\
2857af281eSDavid Howells 	/* rxperf errors */						\
2957af281eSDavid Howells 	EM(rxperf_abort_general_error,		"rxperf-error")		\
3057af281eSDavid Howells 	EM(rxperf_abort_oom,			"rxperf-oom")		\
3157af281eSDavid Howells 	EM(rxperf_abort_op_not_supported,	"rxperf-op-notsupp")	\
3257af281eSDavid Howells 	EM(rxperf_abort_unmarshal_error,	"rxperf-unmarshal")	\
3357af281eSDavid Howells 	/* RxKAD security errors */					\
3457af281eSDavid Howells 	EM(rxkad_abort_1_short_check,		"rxkad1-short-check")	\
3557af281eSDavid Howells 	EM(rxkad_abort_1_short_data,		"rxkad1-short-data")	\
3657af281eSDavid Howells 	EM(rxkad_abort_1_short_encdata,		"rxkad1-short-encdata")	\
3757af281eSDavid Howells 	EM(rxkad_abort_1_short_header,		"rxkad1-short-hdr")	\
3857af281eSDavid Howells 	EM(rxkad_abort_2_short_check,		"rxkad2-short-check")	\
3957af281eSDavid Howells 	EM(rxkad_abort_2_short_data,		"rxkad2-short-data")	\
4057af281eSDavid Howells 	EM(rxkad_abort_2_short_header,		"rxkad2-short-hdr")	\
4157af281eSDavid Howells 	EM(rxkad_abort_2_short_len,		"rxkad2-short-len")	\
4257af281eSDavid Howells 	EM(rxkad_abort_bad_checksum,		"rxkad2-bad-cksum")	\
4357af281eSDavid Howells 	EM(rxkad_abort_chall_key_expired,	"rxkad-chall-key-exp")	\
4457af281eSDavid Howells 	EM(rxkad_abort_chall_level,		"rxkad-chall-level")	\
4557af281eSDavid Howells 	EM(rxkad_abort_chall_no_key,		"rxkad-chall-nokey")	\
4657af281eSDavid Howells 	EM(rxkad_abort_chall_short,		"rxkad-chall-short")	\
4757af281eSDavid Howells 	EM(rxkad_abort_chall_version,		"rxkad-chall-version")	\
4857af281eSDavid Howells 	EM(rxkad_abort_resp_bad_callid,		"rxkad-resp-bad-callid") \
4957af281eSDavid Howells 	EM(rxkad_abort_resp_bad_checksum,	"rxkad-resp-bad-cksum")	\
5057af281eSDavid Howells 	EM(rxkad_abort_resp_bad_param,		"rxkad-resp-bad-param")	\
5157af281eSDavid Howells 	EM(rxkad_abort_resp_call_ctr,		"rxkad-resp-call-ctr") \
5257af281eSDavid Howells 	EM(rxkad_abort_resp_call_state,		"rxkad-resp-call-state") \
5357af281eSDavid Howells 	EM(rxkad_abort_resp_key_expired,	"rxkad-resp-key-exp")	\
5457af281eSDavid Howells 	EM(rxkad_abort_resp_key_rejected,	"rxkad-resp-key-rej")	\
5557af281eSDavid Howells 	EM(rxkad_abort_resp_level,		"rxkad-resp-level")	\
5657af281eSDavid Howells 	EM(rxkad_abort_resp_nokey,		"rxkad-resp-nokey")	\
5757af281eSDavid Howells 	EM(rxkad_abort_resp_ooseq,		"rxkad-resp-ooseq")	\
5857af281eSDavid Howells 	EM(rxkad_abort_resp_short,		"rxkad-resp-short")	\
5957af281eSDavid Howells 	EM(rxkad_abort_resp_short_tkt,		"rxkad-resp-short-tkt")	\
6057af281eSDavid Howells 	EM(rxkad_abort_resp_tkt_aname,		"rxkad-resp-tk-aname")	\
6157af281eSDavid Howells 	EM(rxkad_abort_resp_tkt_expired,	"rxkad-resp-tk-exp")	\
6257af281eSDavid Howells 	EM(rxkad_abort_resp_tkt_future,		"rxkad-resp-tk-future")	\
6357af281eSDavid Howells 	EM(rxkad_abort_resp_tkt_inst,		"rxkad-resp-tk-inst")	\
6457af281eSDavid Howells 	EM(rxkad_abort_resp_tkt_len,		"rxkad-resp-tk-len")	\
6557af281eSDavid Howells 	EM(rxkad_abort_resp_tkt_realm,		"rxkad-resp-tk-realm")	\
6657af281eSDavid Howells 	EM(rxkad_abort_resp_tkt_short,		"rxkad-resp-tk-short")	\
6757af281eSDavid Howells 	EM(rxkad_abort_resp_tkt_sinst,		"rxkad-resp-tk-sinst")	\
6857af281eSDavid Howells 	EM(rxkad_abort_resp_tkt_sname,		"rxkad-resp-tk-sname")	\
6957af281eSDavid Howells 	EM(rxkad_abort_resp_unknown_tkt,	"rxkad-resp-unknown-tkt") \
7057af281eSDavid Howells 	EM(rxkad_abort_resp_version,		"rxkad-resp-version")	\
7157af281eSDavid Howells 	/* rxrpc errors */						\
7257af281eSDavid Howells 	EM(rxrpc_abort_call_improper_term,	"call-improper-term")	\
7357af281eSDavid Howells 	EM(rxrpc_abort_call_reset,		"call-reset")		\
7457af281eSDavid Howells 	EM(rxrpc_abort_call_sendmsg,		"call-sendmsg")		\
7557af281eSDavid Howells 	EM(rxrpc_abort_call_sock_release,	"call-sock-rel")	\
7657af281eSDavid Howells 	EM(rxrpc_abort_call_sock_release_tba,	"call-sock-rel-tba")	\
7757af281eSDavid Howells 	EM(rxrpc_abort_call_timeout,		"call-timeout")		\
7857af281eSDavid Howells 	EM(rxrpc_abort_no_service_key,		"no-serv-key")		\
7957af281eSDavid Howells 	EM(rxrpc_abort_nomem,			"nomem")		\
8057af281eSDavid Howells 	EM(rxrpc_abort_service_not_offered,	"serv-not-offered")	\
8157af281eSDavid Howells 	EM(rxrpc_abort_shut_down,		"shut-down")		\
8257af281eSDavid Howells 	EM(rxrpc_abort_unsupported_security,	"unsup-sec")		\
8357af281eSDavid Howells 	EM(rxrpc_badmsg_bad_abort,		"bad-abort")		\
8457af281eSDavid Howells 	EM(rxrpc_badmsg_bad_jumbo,		"bad-jumbo")		\
8557af281eSDavid Howells 	EM(rxrpc_badmsg_short_ack,		"short-ack")		\
8657af281eSDavid Howells 	EM(rxrpc_badmsg_short_ack_info,		"short-ack-info")	\
8757af281eSDavid Howells 	EM(rxrpc_badmsg_short_hdr,		"short-hdr")		\
8857af281eSDavid Howells 	EM(rxrpc_badmsg_unsupported_packet,	"unsup-pkt")		\
8957af281eSDavid Howells 	EM(rxrpc_badmsg_zero_call,		"zero-call")		\
9057af281eSDavid Howells 	EM(rxrpc_badmsg_zero_seq,		"zero-seq")		\
9157af281eSDavid Howells 	EM(rxrpc_badmsg_zero_service,		"zero-service")		\
9257af281eSDavid Howells 	EM(rxrpc_eproto_ackr_outside_window,	"ackr-out-win")		\
9357af281eSDavid Howells 	EM(rxrpc_eproto_ackr_sack_overflow,	"ackr-sack-over")	\
9457af281eSDavid Howells 	EM(rxrpc_eproto_ackr_short_sack,	"ackr-short-sack")	\
9557af281eSDavid Howells 	EM(rxrpc_eproto_ackr_zero,		"ackr-zero")		\
9657af281eSDavid Howells 	EM(rxrpc_eproto_bad_upgrade,		"bad-upgrade")		\
9757af281eSDavid Howells 	EM(rxrpc_eproto_data_after_last,	"data-after-last")	\
9857af281eSDavid Howells 	EM(rxrpc_eproto_different_last,		"diff-last")		\
9957af281eSDavid Howells 	EM(rxrpc_eproto_early_reply,		"early-reply")		\
10057af281eSDavid Howells 	EM(rxrpc_eproto_improper_term,		"improper-term")	\
10157af281eSDavid Howells 	EM(rxrpc_eproto_no_client_call,		"no-cl-call")		\
10257af281eSDavid Howells 	EM(rxrpc_eproto_no_client_conn,		"no-cl-conn")		\
10357af281eSDavid Howells 	EM(rxrpc_eproto_no_service_call,	"no-sv-call")		\
10457af281eSDavid Howells 	EM(rxrpc_eproto_reupgrade,		"re-upgrade")		\
10557af281eSDavid Howells 	EM(rxrpc_eproto_rxnull_challenge,	"rxnull-chall")		\
10657af281eSDavid Howells 	EM(rxrpc_eproto_rxnull_response,	"rxnull-resp")		\
10757af281eSDavid Howells 	EM(rxrpc_eproto_tx_rot_last,		"tx-rot-last")		\
10857af281eSDavid Howells 	EM(rxrpc_eproto_unexpected_ack,		"unex-ack")		\
10957af281eSDavid Howells 	EM(rxrpc_eproto_unexpected_ackall,	"unex-ackall")		\
11057af281eSDavid Howells 	EM(rxrpc_eproto_unexpected_implicit_end, "unex-impl-end")	\
11157af281eSDavid Howells 	EM(rxrpc_eproto_unexpected_reply,	"unex-reply")		\
11257af281eSDavid Howells 	EM(rxrpc_eproto_wrong_security,		"wrong-sec")		\
11357af281eSDavid Howells 	EM(rxrpc_recvmsg_excess_data,		"recvmsg-excess")	\
11457af281eSDavid Howells 	EM(rxrpc_recvmsg_short_data,		"recvmsg-short")	\
11557af281eSDavid Howells 	E_(rxrpc_sendmsg_late_send,		"sendmsg-late")
11657af281eSDavid Howells 
11715f661dcSDavid Howells #define rxrpc_call_poke_traces \
118a343b174SDavid Howells 	EM(rxrpc_call_poke_abort,		"Abort")	\
11903fc55adSDavid Howells 	EM(rxrpc_call_poke_complete,		"Compl")	\
12015f661dcSDavid Howells 	EM(rxrpc_call_poke_error,		"Error")	\
12115f661dcSDavid Howells 	EM(rxrpc_call_poke_idle,		"Idle")		\
12215f661dcSDavid Howells 	EM(rxrpc_call_poke_start,		"Start")	\
12315f661dcSDavid Howells 	EM(rxrpc_call_poke_timer,		"Timer")	\
12415f661dcSDavid Howells 	E_(rxrpc_call_poke_timer_now,		"Timer-now")
12515f661dcSDavid Howells 
126b54a134aSDavid Howells #define rxrpc_skb_traces \
1279a36a6bcSDavid Howells 	EM(rxrpc_skb_eaten_by_unshare,		"ETN unshare  ") \
1289a36a6bcSDavid Howells 	EM(rxrpc_skb_eaten_by_unshare_nomem,	"ETN unshar-nm") \
1292953d3b8SDavid Howells 	EM(rxrpc_skb_get_conn_secured,		"GET conn-secd") \
1309a36a6bcSDavid Howells 	EM(rxrpc_skb_get_conn_work,		"GET conn-work") \
1312d1faf7aSDavid Howells 	EM(rxrpc_skb_get_local_work,		"GET locl-work") \
1322d1faf7aSDavid Howells 	EM(rxrpc_skb_get_reject_work,		"GET rej-work ") \
1339a36a6bcSDavid Howells 	EM(rxrpc_skb_get_to_recvmsg,		"GET to-recv  ") \
1349a36a6bcSDavid Howells 	EM(rxrpc_skb_get_to_recvmsg_oos,	"GET to-recv-o") \
1359a36a6bcSDavid Howells 	EM(rxrpc_skb_new_encap_rcv,		"NEW encap-rcv") \
1369a36a6bcSDavid Howells 	EM(rxrpc_skb_new_error_report,		"NEW error-rpt") \
1379a36a6bcSDavid Howells 	EM(rxrpc_skb_new_jumbo_subpacket,	"NEW jumbo-sub") \
1389a36a6bcSDavid Howells 	EM(rxrpc_skb_new_unshared,		"NEW unshared ") \
1392953d3b8SDavid Howells 	EM(rxrpc_skb_put_conn_secured,		"PUT conn-secd") \
1409a36a6bcSDavid Howells 	EM(rxrpc_skb_put_conn_work,		"PUT conn-work") \
1419a36a6bcSDavid Howells 	EM(rxrpc_skb_put_error_report,		"PUT error-rep") \
1429a36a6bcSDavid Howells 	EM(rxrpc_skb_put_input,			"PUT input    ") \
1439a36a6bcSDavid Howells 	EM(rxrpc_skb_put_jumbo_subpacket,	"PUT jumbo-sub") \
1449a36a6bcSDavid Howells 	EM(rxrpc_skb_put_purge,			"PUT purge    ") \
1459a36a6bcSDavid Howells 	EM(rxrpc_skb_put_rotate,		"PUT rotate   ") \
1469a36a6bcSDavid Howells 	EM(rxrpc_skb_put_unknown,		"PUT unknown  ") \
1479a36a6bcSDavid Howells 	EM(rxrpc_skb_see_conn_work,		"SEE conn-work") \
1489a36a6bcSDavid Howells 	EM(rxrpc_skb_see_recvmsg,		"SEE recvmsg  ") \
1499a36a6bcSDavid Howells 	EM(rxrpc_skb_see_reject,		"SEE reject   ") \
1509a36a6bcSDavid Howells 	EM(rxrpc_skb_see_rotate,		"SEE rotate   ") \
1519a36a6bcSDavid Howells 	E_(rxrpc_skb_see_version,		"SEE version  ")
152b54a134aSDavid Howells 
15309d2bf59SDavid Howells #define rxrpc_local_traces \
1540fde882fSDavid Howells 	EM(rxrpc_local_free,			"FREE        ") \
155f3441d41SDavid Howells 	EM(rxrpc_local_get_call,		"GET call    ") \
1560fde882fSDavid Howells 	EM(rxrpc_local_get_client_conn,		"GET conn-cln") \
1570fde882fSDavid Howells 	EM(rxrpc_local_get_for_use,		"GET for-use ") \
1580fde882fSDavid Howells 	EM(rxrpc_local_get_peer,		"GET peer    ") \
1590fde882fSDavid Howells 	EM(rxrpc_local_get_prealloc_conn,	"GET conn-pre") \
16009d2bf59SDavid Howells 	EM(rxrpc_local_new,			"NEW         ") \
1610fde882fSDavid Howells 	EM(rxrpc_local_put_bind,		"PUT bind    ") \
162f3441d41SDavid Howells 	EM(rxrpc_local_put_call,		"PUT call    ") \
1630fde882fSDavid Howells 	EM(rxrpc_local_put_for_use,		"PUT for-use ") \
1640fde882fSDavid Howells 	EM(rxrpc_local_put_kill_conn,		"PUT conn-kil") \
1650fde882fSDavid Howells 	EM(rxrpc_local_put_peer,		"PUT peer    ") \
1668395406bSDavid Howells 	EM(rxrpc_local_put_prealloc_peer,	"PUT peer-pre") \
1670fde882fSDavid Howells 	EM(rxrpc_local_put_release_sock,	"PUT rel-sock") \
1680fde882fSDavid Howells 	EM(rxrpc_local_stop,			"STOP        ") \
1690fde882fSDavid Howells 	EM(rxrpc_local_stopped,			"STOPPED     ") \
1700fde882fSDavid Howells 	EM(rxrpc_local_unuse_bind,		"UNU bind    ") \
1710fde882fSDavid Howells 	EM(rxrpc_local_unuse_conn_work,		"UNU conn-wrk") \
1720fde882fSDavid Howells 	EM(rxrpc_local_unuse_peer_keepalive,	"UNU peer-kpa") \
1730fde882fSDavid Howells 	EM(rxrpc_local_unuse_release_sock,	"UNU rel-sock") \
1740fde882fSDavid Howells 	EM(rxrpc_local_use_conn_work,		"USE conn-wrk") \
1750fde882fSDavid Howells 	EM(rxrpc_local_use_lookup,		"USE lookup  ") \
1765e6ef4f1SDavid Howells 	E_(rxrpc_local_use_peer_keepalive,	"USE peer-kpa")
17709d2bf59SDavid Howells 
1781159d4b4SDavid Howells #define rxrpc_peer_traces \
17947c810a7SDavid Howells 	EM(rxrpc_peer_free,			"FREE        ") \
18047c810a7SDavid Howells 	EM(rxrpc_peer_get_accept,		"GET accept  ") \
18147c810a7SDavid Howells 	EM(rxrpc_peer_get_bundle,		"GET bundle  ") \
18247c810a7SDavid Howells 	EM(rxrpc_peer_get_client_conn,		"GET cln-conn") \
1835e6ef4f1SDavid Howells 	EM(rxrpc_peer_get_input,		"GET input   ") \
18447c810a7SDavid Howells 	EM(rxrpc_peer_get_input_error,		"GET inpt-err") \
18547c810a7SDavid Howells 	EM(rxrpc_peer_get_keepalive,		"GET keepaliv") \
18647c810a7SDavid Howells 	EM(rxrpc_peer_get_lookup_client,	"GET look-cln") \
18747c810a7SDavid Howells 	EM(rxrpc_peer_get_service_conn,		"GET srv-conn") \
18847c810a7SDavid Howells 	EM(rxrpc_peer_new_client,		"NEW client  ") \
18947c810a7SDavid Howells 	EM(rxrpc_peer_new_prealloc,		"NEW prealloc") \
19047c810a7SDavid Howells 	EM(rxrpc_peer_put_bundle,		"PUT bundle  ") \
19147c810a7SDavid Howells 	EM(rxrpc_peer_put_call,			"PUT call    ") \
19247c810a7SDavid Howells 	EM(rxrpc_peer_put_conn,			"PUT conn    ") \
1935e6ef4f1SDavid Howells 	EM(rxrpc_peer_put_input,		"PUT input   ") \
19447c810a7SDavid Howells 	EM(rxrpc_peer_put_input_error,		"PUT inpt-err") \
19547c810a7SDavid Howells 	E_(rxrpc_peer_put_keepalive,		"PUT keepaliv")
1961159d4b4SDavid Howells 
197fa3492abSDavid Howells #define rxrpc_bundle_traces \
198fa3492abSDavid Howells 	EM(rxrpc_bundle_free,			"FREE        ") \
199fa3492abSDavid Howells 	EM(rxrpc_bundle_get_client_call,	"GET clt-call") \
200fa3492abSDavid Howells 	EM(rxrpc_bundle_get_client_conn,	"GET clt-conn") \
201fa3492abSDavid Howells 	EM(rxrpc_bundle_get_service_conn,	"GET svc-conn") \
2021bab27afSDavid Howells 	EM(rxrpc_bundle_put_call,		"PUT call    ") \
203fa3492abSDavid Howells 	EM(rxrpc_bundle_put_conn,		"PUT conn    ") \
204fa3492abSDavid Howells 	EM(rxrpc_bundle_put_discard,		"PUT discard ") \
205fa3492abSDavid Howells 	E_(rxrpc_bundle_new,			"NEW         ")
206fa3492abSDavid Howells 
207b54a134aSDavid Howells #define rxrpc_conn_traces \
2087fa25105SDavid Howells 	EM(rxrpc_conn_free,			"FREE        ") \
2097fa25105SDavid Howells 	EM(rxrpc_conn_get_activate_call,	"GET act-call") \
2107fa25105SDavid Howells 	EM(rxrpc_conn_get_call_input,		"GET inp-call") \
2117fa25105SDavid Howells 	EM(rxrpc_conn_get_conn_input,		"GET inp-conn") \
2127fa25105SDavid Howells 	EM(rxrpc_conn_get_idle,			"GET idle    ") \
213a00ce28bSDavid Howells 	EM(rxrpc_conn_get_poke_abort,		"GET pk-abort") \
214f2cce89aSDavid Howells 	EM(rxrpc_conn_get_poke_timer,		"GET poke    ") \
2157fa25105SDavid Howells 	EM(rxrpc_conn_get_service_conn,		"GET svc-conn") \
2167fa25105SDavid Howells 	EM(rxrpc_conn_new_client,		"NEW client  ") \
2177fa25105SDavid Howells 	EM(rxrpc_conn_new_service,		"NEW service ") \
2187fa25105SDavid Howells 	EM(rxrpc_conn_put_call,			"PUT call    ") \
2197fa25105SDavid Howells 	EM(rxrpc_conn_put_call_input,		"PUT inp-call") \
2207fa25105SDavid Howells 	EM(rxrpc_conn_put_conn_input,		"PUT inp-conn") \
2217fa25105SDavid Howells 	EM(rxrpc_conn_put_discard_idle,		"PUT disc-idl") \
2227fa25105SDavid Howells 	EM(rxrpc_conn_put_local_dead,		"PUT loc-dead") \
2237fa25105SDavid Howells 	EM(rxrpc_conn_put_noreuse,		"PUT noreuse ") \
2247fa25105SDavid Howells 	EM(rxrpc_conn_put_poke,			"PUT poke    ") \
2253cec055cSDavid Howells 	EM(rxrpc_conn_put_service_reaped,	"PUT svc-reap") \
2267fa25105SDavid Howells 	EM(rxrpc_conn_put_unbundle,		"PUT unbundle") \
2277fa25105SDavid Howells 	EM(rxrpc_conn_put_unidle,		"PUT unidle  ") \
228f2cce89aSDavid Howells 	EM(rxrpc_conn_put_work,			"PUT work    ") \
2293cec055cSDavid Howells 	EM(rxrpc_conn_queue_challenge,		"QUE chall   ") \
230a00ce28bSDavid Howells 	EM(rxrpc_conn_queue_retry_work,		"QUE retry-wk") \
2313cec055cSDavid Howells 	EM(rxrpc_conn_queue_rx_work,		"QUE rx-work ") \
2327fa25105SDavid Howells 	EM(rxrpc_conn_see_new_service_conn,	"SEE new-svc ") \
2337fa25105SDavid Howells 	EM(rxrpc_conn_see_reap_service,		"SEE reap-svc") \
2347fa25105SDavid Howells 	E_(rxrpc_conn_see_work,			"SEE work    ")
235b54a134aSDavid Howells 
236b54a134aSDavid Howells #define rxrpc_client_traces \
237b54a134aSDavid Howells 	EM(rxrpc_client_activate_chans,		"Activa") \
238b54a134aSDavid Howells 	EM(rxrpc_client_alloc,			"Alloc ") \
239b54a134aSDavid Howells 	EM(rxrpc_client_chan_activate,		"ChActv") \
240b54a134aSDavid Howells 	EM(rxrpc_client_chan_disconnect,	"ChDisc") \
241b54a134aSDavid Howells 	EM(rxrpc_client_chan_pass,		"ChPass") \
242b54a134aSDavid Howells 	EM(rxrpc_client_cleanup,		"Clean ") \
243b54a134aSDavid Howells 	EM(rxrpc_client_discard,		"Discar") \
244b54a134aSDavid Howells 	EM(rxrpc_client_exposed,		"Expose") \
245b54a134aSDavid Howells 	EM(rxrpc_client_replace,		"Replac") \
2469d35d880SDavid Howells 	EM(rxrpc_client_queue_new_call,		"Q-Call") \
247b54a134aSDavid Howells 	EM(rxrpc_client_to_active,		"->Actv") \
248245500d8SDavid Howells 	E_(rxrpc_client_to_idle,		"->Idle")
249b54a134aSDavid Howells 
250b54a134aSDavid Howells #define rxrpc_call_traces \
2515040011dSDavid Howells 	EM(rxrpc_call_get_io_thread,		"GET iothread") \
252cb0fc0c9SDavid Howells 	EM(rxrpc_call_get_input,		"GET input   ") \
253cb0fc0c9SDavid Howells 	EM(rxrpc_call_get_kernel_service,	"GET krnl-srv") \
254cb0fc0c9SDavid Howells 	EM(rxrpc_call_get_notify_socket,	"GET notify  ") \
25515f661dcSDavid Howells 	EM(rxrpc_call_get_poke,			"GET poke    ") \
256cb0fc0c9SDavid Howells 	EM(rxrpc_call_get_recvmsg,		"GET recvmsg ") \
257cb0fc0c9SDavid Howells 	EM(rxrpc_call_get_release_sock,		"GET rel-sock") \
258cb0fc0c9SDavid Howells 	EM(rxrpc_call_get_sendmsg,		"GET sendmsg ") \
259cb0fc0c9SDavid Howells 	EM(rxrpc_call_get_userid,		"GET user-id ") \
260cb0fc0c9SDavid Howells 	EM(rxrpc_call_new_client,		"NEW client  ") \
261cb0fc0c9SDavid Howells 	EM(rxrpc_call_new_prealloc_service,	"NEW prealloc") \
262cb0fc0c9SDavid Howells 	EM(rxrpc_call_put_discard_prealloc,	"PUT disc-pre") \
263f3441d41SDavid Howells 	EM(rxrpc_call_put_discard_error,	"PUT disc-err") \
2645040011dSDavid Howells 	EM(rxrpc_call_put_io_thread,		"PUT iothread") \
265cb0fc0c9SDavid Howells 	EM(rxrpc_call_put_input,		"PUT input   ") \
266cb0fc0c9SDavid Howells 	EM(rxrpc_call_put_kernel,		"PUT kernel  ") \
26715f661dcSDavid Howells 	EM(rxrpc_call_put_poke,			"PUT poke    ") \
268cb0fc0c9SDavid Howells 	EM(rxrpc_call_put_recvmsg,		"PUT recvmsg ") \
269cb0fc0c9SDavid Howells 	EM(rxrpc_call_put_release_sock,		"PUT rls-sock") \
270cb0fc0c9SDavid Howells 	EM(rxrpc_call_put_release_sock_tba,	"PUT rls-sk-a") \
271cb0fc0c9SDavid Howells 	EM(rxrpc_call_put_sendmsg,		"PUT sendmsg ") \
272cb0fc0c9SDavid Howells 	EM(rxrpc_call_put_unnotify,		"PUT unnotify") \
273cb0fc0c9SDavid Howells 	EM(rxrpc_call_put_userid_exists,	"PUT u-exists") \
2749d35d880SDavid Howells 	EM(rxrpc_call_put_userid,		"PUT user-id ") \
275cb0fc0c9SDavid Howells 	EM(rxrpc_call_see_accept,		"SEE accept  ") \
276cb0fc0c9SDavid Howells 	EM(rxrpc_call_see_activate_client,	"SEE act-clnt") \
277cb0fc0c9SDavid Howells 	EM(rxrpc_call_see_connect_failed,	"SEE con-fail") \
278cb0fc0c9SDavid Howells 	EM(rxrpc_call_see_connected,		"SEE connect ") \
2795040011dSDavid Howells 	EM(rxrpc_call_see_disconnected,		"SEE disconn ") \
280cb0fc0c9SDavid Howells 	EM(rxrpc_call_see_distribute_error,	"SEE dist-err") \
281cb0fc0c9SDavid Howells 	EM(rxrpc_call_see_input,		"SEE input   ") \
282cb0fc0c9SDavid Howells 	EM(rxrpc_call_see_release,		"SEE release ") \
283cb0fc0c9SDavid Howells 	EM(rxrpc_call_see_userid_exists,	"SEE u-exists") \
284cb0fc0c9SDavid Howells 	E_(rxrpc_call_see_zap,			"SEE zap     ")
285b54a134aSDavid Howells 
286a4ea4c47SDavid Howells #define rxrpc_txqueue_traces \
287a4ea4c47SDavid Howells 	EM(rxrpc_txqueue_await_reply,		"AWR") \
288a4ea4c47SDavid Howells 	EM(rxrpc_txqueue_dequeue,		"DEQ") \
289a4ea4c47SDavid Howells 	EM(rxrpc_txqueue_end,			"END") \
290a4ea4c47SDavid Howells 	EM(rxrpc_txqueue_queue,			"QUE") \
291a4ea4c47SDavid Howells 	EM(rxrpc_txqueue_queue_last,		"QLS") \
292a4ea4c47SDavid Howells 	EM(rxrpc_txqueue_rotate,		"ROT") \
293a4ea4c47SDavid Howells 	EM(rxrpc_txqueue_rotate_last,		"RLS") \
294a4ea4c47SDavid Howells 	E_(rxrpc_txqueue_wait,			"WAI")
295b54a134aSDavid Howells 
296b54a134aSDavid Howells #define rxrpc_receive_traces \
297b54a134aSDavid Howells 	EM(rxrpc_receive_end,			"END") \
298b54a134aSDavid Howells 	EM(rxrpc_receive_front,			"FRN") \
299b54a134aSDavid Howells 	EM(rxrpc_receive_incoming,		"INC") \
300b54a134aSDavid Howells 	EM(rxrpc_receive_queue,			"QUE") \
301b54a134aSDavid Howells 	EM(rxrpc_receive_queue_last,		"QLS") \
3025d7edbc9SDavid Howells 	EM(rxrpc_receive_queue_oos,		"QUO") \
3035d7edbc9SDavid Howells 	EM(rxrpc_receive_queue_oos_last,	"QOL") \
3045d7edbc9SDavid Howells 	EM(rxrpc_receive_oos,			"OOS") \
3055d7edbc9SDavid Howells 	EM(rxrpc_receive_oos_last,		"OSL") \
3065d7edbc9SDavid Howells 	EM(rxrpc_receive_rotate,		"ROT") \
3075d7edbc9SDavid Howells 	E_(rxrpc_receive_rotate_last,		"RLS")
308b54a134aSDavid Howells 
309b54a134aSDavid Howells #define rxrpc_recvmsg_traces \
310b54a134aSDavid Howells 	EM(rxrpc_recvmsg_cont,			"CONT") \
311b54a134aSDavid Howells 	EM(rxrpc_recvmsg_data_return,		"DATA") \
312b54a134aSDavid Howells 	EM(rxrpc_recvmsg_dequeue,		"DEQU") \
313b54a134aSDavid Howells 	EM(rxrpc_recvmsg_enter,			"ENTR") \
314b54a134aSDavid Howells 	EM(rxrpc_recvmsg_full,			"FULL") \
315b54a134aSDavid Howells 	EM(rxrpc_recvmsg_hole,			"HOLE") \
316b54a134aSDavid Howells 	EM(rxrpc_recvmsg_next,			"NEXT") \
317540b1c48SDavid Howells 	EM(rxrpc_recvmsg_requeue,		"REQU") \
318b54a134aSDavid Howells 	EM(rxrpc_recvmsg_return,		"RETN") \
319b54a134aSDavid Howells 	EM(rxrpc_recvmsg_terminal,		"TERM") \
320b54a134aSDavid Howells 	EM(rxrpc_recvmsg_to_be_accepted,	"TBAC") \
321*c0783818SDavid Howells 	EM(rxrpc_recvmsg_unqueue,		"UNQU") \
322b54a134aSDavid Howells 	E_(rxrpc_recvmsg_wait,			"WAIT")
323b54a134aSDavid Howells 
324b54a134aSDavid Howells #define rxrpc_rtt_tx_traces \
3254700c4d8SDavid Howells 	EM(rxrpc_rtt_tx_cancel,			"CNCE") \
326b54a134aSDavid Howells 	EM(rxrpc_rtt_tx_data,			"DATA") \
3274700c4d8SDavid Howells 	EM(rxrpc_rtt_tx_no_slot,		"FULL") \
328b54a134aSDavid Howells 	E_(rxrpc_rtt_tx_ping,			"PING")
329b54a134aSDavid Howells 
330b54a134aSDavid Howells #define rxrpc_rtt_rx_traces \
3314700c4d8SDavid Howells 	EM(rxrpc_rtt_rx_cancel,			"CNCL") \
3324700c4d8SDavid Howells 	EM(rxrpc_rtt_rx_obsolete,		"OBSL") \
3334700c4d8SDavid Howells 	EM(rxrpc_rtt_rx_lost,			"LOST") \
334b54a134aSDavid Howells 	EM(rxrpc_rtt_rx_ping_response,		"PONG") \
335b54a134aSDavid Howells 	E_(rxrpc_rtt_rx_requested_ack,		"RACK")
336b54a134aSDavid Howells 
337b54a134aSDavid Howells #define rxrpc_timer_traces \
338b54a134aSDavid Howells 	EM(rxrpc_timer_begin,			"Begin ") \
339a158bdd3SDavid Howells 	EM(rxrpc_timer_exp_ack,			"ExpAck") \
340a158bdd3SDavid Howells 	EM(rxrpc_timer_exp_hard,		"ExpHrd") \
341a158bdd3SDavid Howells 	EM(rxrpc_timer_exp_idle,		"ExpIdl") \
342415f44e4SDavid Howells 	EM(rxrpc_timer_exp_keepalive,		"ExpKA ") \
343bd1fdf8cSDavid Howells 	EM(rxrpc_timer_exp_lost_ack,		"ExpLoA") \
344a158bdd3SDavid Howells 	EM(rxrpc_timer_exp_normal,		"ExpNml") \
345a158bdd3SDavid Howells 	EM(rxrpc_timer_exp_ping,		"ExpPng") \
346a158bdd3SDavid Howells 	EM(rxrpc_timer_exp_resend,		"ExpRsn") \
347b54a134aSDavid Howells 	EM(rxrpc_timer_init_for_reply,		"IniRpl") \
348b54a134aSDavid Howells 	EM(rxrpc_timer_init_for_send_reply,	"SndRpl") \
349a158bdd3SDavid Howells 	EM(rxrpc_timer_restart,			"Restrt") \
350b54a134aSDavid Howells 	EM(rxrpc_timer_set_for_ack,		"SetAck") \
351a158bdd3SDavid Howells 	EM(rxrpc_timer_set_for_hard,		"SetHrd") \
352a158bdd3SDavid Howells 	EM(rxrpc_timer_set_for_idle,		"SetIdl") \
353415f44e4SDavid Howells 	EM(rxrpc_timer_set_for_keepalive,	"KeepAl") \
354bd1fdf8cSDavid Howells 	EM(rxrpc_timer_set_for_lost_ack,	"SetLoA") \
355a158bdd3SDavid Howells 	EM(rxrpc_timer_set_for_normal,		"SetNml") \
356b54a134aSDavid Howells 	EM(rxrpc_timer_set_for_ping,		"SetPng") \
357b54a134aSDavid Howells 	EM(rxrpc_timer_set_for_resend,		"SetRTx") \
358a158bdd3SDavid Howells 	E_(rxrpc_timer_set_for_send,		"SetSnd")
359b54a134aSDavid Howells 
360b54a134aSDavid Howells #define rxrpc_propose_ack_traces \
361b54a134aSDavid Howells 	EM(rxrpc_propose_ack_client_tx_end,	"ClTxEnd") \
362b54a134aSDavid Howells 	EM(rxrpc_propose_ack_input_data,	"DataIn ") \
363530403d9SDavid Howells 	EM(rxrpc_propose_ack_input_data_hole,	"DataInH") \
364415f44e4SDavid Howells 	EM(rxrpc_propose_ack_ping_for_keepalive, "KeepAlv") \
365b54a134aSDavid Howells 	EM(rxrpc_propose_ack_ping_for_lost_ack,	"LostAck") \
366b54a134aSDavid Howells 	EM(rxrpc_propose_ack_ping_for_lost_reply, "LostRpl") \
36784e28aa5SDavid Howells 	EM(rxrpc_propose_ack_ping_for_old_rtt,	"OldRtt ") \
368b54a134aSDavid Howells 	EM(rxrpc_propose_ack_ping_for_params,	"Params ") \
36984e28aa5SDavid Howells 	EM(rxrpc_propose_ack_ping_for_rtt,	"Rtt    ") \
370b54a134aSDavid Howells 	EM(rxrpc_propose_ack_processing_op,	"ProcOp ") \
371b54a134aSDavid Howells 	EM(rxrpc_propose_ack_respond_to_ack,	"Rsp2Ack") \
372b54a134aSDavid Howells 	EM(rxrpc_propose_ack_respond_to_ping,	"Rsp2Png") \
373b54a134aSDavid Howells 	EM(rxrpc_propose_ack_retry_tx,		"RetryTx") \
374b54a134aSDavid Howells 	EM(rxrpc_propose_ack_rotate_rx,		"RxAck  ") \
3755e6ef4f1SDavid Howells 	EM(rxrpc_propose_ack_rx_idle,		"RxIdle ") \
376b54a134aSDavid Howells 	E_(rxrpc_propose_ack_terminal_ack,	"ClTerm ")
377b54a134aSDavid Howells 
378b54a134aSDavid Howells #define rxrpc_congest_modes \
379b54a134aSDavid Howells 	EM(RXRPC_CALL_CONGEST_AVOIDANCE,	"CongAvoid") \
380b54a134aSDavid Howells 	EM(RXRPC_CALL_FAST_RETRANSMIT,		"FastReTx ") \
381b54a134aSDavid Howells 	EM(RXRPC_CALL_PACKET_LOSS,		"PktLoss  ") \
382b54a134aSDavid Howells 	E_(RXRPC_CALL_SLOW_START,		"SlowStart")
383b54a134aSDavid Howells 
384b54a134aSDavid Howells #define rxrpc_congest_changes \
385b54a134aSDavid Howells 	EM(rxrpc_cong_begin_retransmission,	" Retrans") \
386b54a134aSDavid Howells 	EM(rxrpc_cong_cleared_nacks,		" Cleared") \
387b54a134aSDavid Howells 	EM(rxrpc_cong_new_low_nack,		" NewLowN") \
388aadf9dceSDavid Howells 	EM(rxrpc_cong_no_change,		" -") \
389b54a134aSDavid Howells 	EM(rxrpc_cong_progress,			" Progres") \
3901fc4fa2aSDavid Howells 	EM(rxrpc_cong_idle_reset,		" IdleRes") \
391b54a134aSDavid Howells 	EM(rxrpc_cong_retransmit_again,		" ReTxAgn") \
392b54a134aSDavid Howells 	EM(rxrpc_cong_rtt_window_end,		" RttWinE") \
393b54a134aSDavid Howells 	E_(rxrpc_cong_saw_nack,			" SawNack")
394b54a134aSDavid Howells 
395b54a134aSDavid Howells #define rxrpc_pkts \
396b54a134aSDavid Howells 	EM(0,					"?00") \
397b54a134aSDavid Howells 	EM(RXRPC_PACKET_TYPE_DATA,		"DATA") \
398b54a134aSDavid Howells 	EM(RXRPC_PACKET_TYPE_ACK,		"ACK") \
399b54a134aSDavid Howells 	EM(RXRPC_PACKET_TYPE_BUSY,		"BUSY") \
400b54a134aSDavid Howells 	EM(RXRPC_PACKET_TYPE_ABORT,		"ABORT") \
401b54a134aSDavid Howells 	EM(RXRPC_PACKET_TYPE_ACKALL,		"ACKALL") \
402b54a134aSDavid Howells 	EM(RXRPC_PACKET_TYPE_CHALLENGE,		"CHALL") \
403b54a134aSDavid Howells 	EM(RXRPC_PACKET_TYPE_RESPONSE,		"RESP") \
404b54a134aSDavid Howells 	EM(RXRPC_PACKET_TYPE_DEBUG,		"DEBUG") \
405b54a134aSDavid Howells 	EM(9,					"?09") \
406b54a134aSDavid Howells 	EM(10,					"?10") \
407b54a134aSDavid Howells 	EM(11,					"?11") \
408b54a134aSDavid Howells 	EM(12,					"?12") \
409b54a134aSDavid Howells 	EM(RXRPC_PACKET_TYPE_VERSION,		"VERSION") \
410b54a134aSDavid Howells 	EM(14,					"?14") \
411b54a134aSDavid Howells 	E_(15,					"?15")
412b54a134aSDavid Howells 
413b54a134aSDavid Howells #define rxrpc_ack_names \
414b54a134aSDavid Howells 	EM(0,					"-0-") \
415b54a134aSDavid Howells 	EM(RXRPC_ACK_REQUESTED,			"REQ") \
416b54a134aSDavid Howells 	EM(RXRPC_ACK_DUPLICATE,			"DUP") \
417b54a134aSDavid Howells 	EM(RXRPC_ACK_OUT_OF_SEQUENCE,		"OOS") \
418b54a134aSDavid Howells 	EM(RXRPC_ACK_EXCEEDS_WINDOW,		"WIN") \
419b54a134aSDavid Howells 	EM(RXRPC_ACK_NOSPACE,			"MEM") \
420b54a134aSDavid Howells 	EM(RXRPC_ACK_PING,			"PNG") \
421b54a134aSDavid Howells 	EM(RXRPC_ACK_PING_RESPONSE,		"PNR") \
422b54a134aSDavid Howells 	EM(RXRPC_ACK_DELAY,			"DLY") \
423b54a134aSDavid Howells 	EM(RXRPC_ACK_IDLE,			"IDL") \
424b54a134aSDavid Howells 	E_(RXRPC_ACK__INVALID,			"-?-")
425b54a134aSDavid Howells 
426f21e9348SDavid Howells #define rxrpc_sack_traces \
427f21e9348SDavid Howells 	EM(rxrpc_sack_advance,			"ADV")	\
428f21e9348SDavid Howells 	EM(rxrpc_sack_fill,			"FIL")	\
429f21e9348SDavid Howells 	EM(rxrpc_sack_nack,			"NAK")	\
430f21e9348SDavid Howells 	EM(rxrpc_sack_none,			"---")	\
431f21e9348SDavid Howells 	E_(rxrpc_sack_oos,			"OOS")
432f21e9348SDavid Howells 
4331bae5d22SDavid Howells #define rxrpc_completions \
4341bae5d22SDavid Howells 	EM(RXRPC_CALL_SUCCEEDED,		"Succeeded") \
4351bae5d22SDavid Howells 	EM(RXRPC_CALL_REMOTELY_ABORTED,		"RemoteAbort") \
4361bae5d22SDavid Howells 	EM(RXRPC_CALL_LOCALLY_ABORTED,		"LocalAbort") \
4371bae5d22SDavid Howells 	EM(RXRPC_CALL_LOCAL_ERROR,		"LocalError") \
4381bae5d22SDavid Howells 	E_(RXRPC_CALL_NETWORK_ERROR,		"NetError")
4391bae5d22SDavid Howells 
4404764c0daSDavid Howells #define rxrpc_tx_points \
4414764c0daSDavid Howells 	EM(rxrpc_tx_point_call_abort,		"CallAbort") \
4424764c0daSDavid Howells 	EM(rxrpc_tx_point_call_ack,		"CallAck") \
4434764c0daSDavid Howells 	EM(rxrpc_tx_point_call_data_frag,	"CallDataFrag") \
4444764c0daSDavid Howells 	EM(rxrpc_tx_point_call_data_nofrag,	"CallDataNofrag") \
4454764c0daSDavid Howells 	EM(rxrpc_tx_point_call_final_resend,	"CallFinalResend") \
4464764c0daSDavid Howells 	EM(rxrpc_tx_point_conn_abort,		"ConnAbort") \
4474764c0daSDavid Howells 	EM(rxrpc_tx_point_reject,		"Reject") \
4484764c0daSDavid Howells 	EM(rxrpc_tx_point_rxkad_challenge,	"RxkadChall") \
4494764c0daSDavid Howells 	EM(rxrpc_tx_point_rxkad_response,	"RxkadResp") \
4504764c0daSDavid Howells 	EM(rxrpc_tx_point_version_keepalive,	"VerKeepalive") \
4514764c0daSDavid Howells 	E_(rxrpc_tx_point_version_reply,	"VerReply")
4526b47fe1dSDavid Howells 
4534d843be5SDavid Howells #define rxrpc_req_ack_traces \
4544d843be5SDavid Howells 	EM(rxrpc_reqack_ack_lost,		"ACK-LOST  ")	\
4554d843be5SDavid Howells 	EM(rxrpc_reqack_already_on,		"ALREADY-ON")	\
4564d843be5SDavid Howells 	EM(rxrpc_reqack_more_rtt,		"MORE-RTT  ")	\
4574d843be5SDavid Howells 	EM(rxrpc_reqack_no_srv_last,		"NO-SRVLAST")	\
4584d843be5SDavid Howells 	EM(rxrpc_reqack_old_rtt,		"OLD-RTT   ")	\
4594d843be5SDavid Howells 	EM(rxrpc_reqack_retrans,		"RETRANS   ")	\
4604d843be5SDavid Howells 	EM(rxrpc_reqack_slow_start,		"SLOW-START")	\
4614d843be5SDavid Howells 	E_(rxrpc_reqack_small_txwin,		"SMALL-TXWN")
462f7fa5242SDavid Howells /* ---- Must update size of stat_why_req_ack[] if more are added! */
4634d843be5SDavid Howells 
46402a19356SDavid Howells #define rxrpc_txbuf_traces \
46502a19356SDavid Howells 	EM(rxrpc_txbuf_alloc_ack,		"ALLOC ACK  ")	\
46602a19356SDavid Howells 	EM(rxrpc_txbuf_alloc_data,		"ALLOC DATA ")	\
46702a19356SDavid Howells 	EM(rxrpc_txbuf_free,			"FREE       ")	\
468a4ea4c47SDavid Howells 	EM(rxrpc_txbuf_get_buffer,		"GET BUFFER ")	\
46902a19356SDavid Howells 	EM(rxrpc_txbuf_get_trans,		"GET TRANS  ")	\
47002a19356SDavid Howells 	EM(rxrpc_txbuf_get_retrans,		"GET RETRANS")	\
47172f0c6fbSDavid Howells 	EM(rxrpc_txbuf_put_ack_tx,		"PUT ACK TX ")	\
47202a19356SDavid Howells 	EM(rxrpc_txbuf_put_cleaned,		"PUT CLEANED")	\
47372f0c6fbSDavid Howells 	EM(rxrpc_txbuf_put_nomem,		"PUT NOMEM  ")	\
47402a19356SDavid Howells 	EM(rxrpc_txbuf_put_rotated,		"PUT ROTATED")	\
47502a19356SDavid Howells 	EM(rxrpc_txbuf_put_send_aborted,	"PUT SEND-X ")	\
476a4ea4c47SDavid Howells 	EM(rxrpc_txbuf_put_trans,		"PUT TRANS  ")	\
4773feda9d6SDavid Howells 	EM(rxrpc_txbuf_see_out_of_step,		"OUT-OF-STEP")	\
47802a19356SDavid Howells 	EM(rxrpc_txbuf_see_send_more,		"SEE SEND+  ")	\
47902a19356SDavid Howells 	E_(rxrpc_txbuf_see_unacked,		"SEE UNACKED")
48002a19356SDavid Howells 
481b54a134aSDavid Howells /*
482dc9fd093SDavid Howells  * Generate enums for tracing information.
483dc9fd093SDavid Howells  */
484dc9fd093SDavid Howells #ifndef __NETFS_DECLARE_TRACE_ENUMS_ONCE_ONLY
485dc9fd093SDavid Howells #define __NETFS_DECLARE_TRACE_ENUMS_ONCE_ONLY
486dc9fd093SDavid Howells 
487dc9fd093SDavid Howells #undef EM
488dc9fd093SDavid Howells #undef E_
489dc9fd093SDavid Howells #define EM(a, b) a,
490dc9fd093SDavid Howells #define E_(a, b) a
491dc9fd093SDavid Howells 
49257af281eSDavid Howells enum rxrpc_abort_reason		{ rxrpc_abort_reasons } __mode(byte);
493fa3492abSDavid Howells enum rxrpc_bundle_trace		{ rxrpc_bundle_traces } __mode(byte);
49415f661dcSDavid Howells enum rxrpc_call_poke_trace	{ rxrpc_call_poke_traces } __mode(byte);
495dc9fd093SDavid Howells enum rxrpc_call_trace		{ rxrpc_call_traces } __mode(byte);
496dc9fd093SDavid Howells enum rxrpc_client_trace		{ rxrpc_client_traces } __mode(byte);
497dc9fd093SDavid Howells enum rxrpc_congest_change	{ rxrpc_congest_changes } __mode(byte);
498dc9fd093SDavid Howells enum rxrpc_conn_trace		{ rxrpc_conn_traces } __mode(byte);
499dc9fd093SDavid Howells enum rxrpc_local_trace		{ rxrpc_local_traces } __mode(byte);
500dc9fd093SDavid Howells enum rxrpc_peer_trace		{ rxrpc_peer_traces } __mode(byte);
501dc9fd093SDavid Howells enum rxrpc_propose_ack_outcome	{ rxrpc_propose_ack_outcomes } __mode(byte);
502dc9fd093SDavid Howells enum rxrpc_propose_ack_trace	{ rxrpc_propose_ack_traces } __mode(byte);
503dc9fd093SDavid Howells enum rxrpc_receive_trace	{ rxrpc_receive_traces } __mode(byte);
504dc9fd093SDavid Howells enum rxrpc_recvmsg_trace	{ rxrpc_recvmsg_traces } __mode(byte);
5054d843be5SDavid Howells enum rxrpc_req_ack_trace	{ rxrpc_req_ack_traces } __mode(byte);
506dc9fd093SDavid Howells enum rxrpc_rtt_rx_trace		{ rxrpc_rtt_rx_traces } __mode(byte);
507dc9fd093SDavid Howells enum rxrpc_rtt_tx_trace		{ rxrpc_rtt_tx_traces } __mode(byte);
508f21e9348SDavid Howells enum rxrpc_sack_trace		{ rxrpc_sack_traces } __mode(byte);
509dc9fd093SDavid Howells enum rxrpc_skb_trace		{ rxrpc_skb_traces } __mode(byte);
510dc9fd093SDavid Howells enum rxrpc_timer_trace		{ rxrpc_timer_traces } __mode(byte);
511dc9fd093SDavid Howells enum rxrpc_tx_point		{ rxrpc_tx_points } __mode(byte);
51202a19356SDavid Howells enum rxrpc_txbuf_trace		{ rxrpc_txbuf_traces } __mode(byte);
513a4ea4c47SDavid Howells enum rxrpc_txqueue_trace	{ rxrpc_txqueue_traces } __mode(byte);
514dc9fd093SDavid Howells 
515dc9fd093SDavid Howells #endif /* end __RXRPC_DECLARE_TRACE_ENUMS_ONCE_ONLY */
516dc9fd093SDavid Howells 
517dc9fd093SDavid Howells /*
518b54a134aSDavid Howells  * Export enum symbols via userspace.
519b54a134aSDavid Howells  */
520b54a134aSDavid Howells #undef EM
521b54a134aSDavid Howells #undef E_
52257af281eSDavid Howells 
52357af281eSDavid Howells #ifndef RXRPC_TRACE_ONLY_DEFINE_ENUMS
52457af281eSDavid Howells 
525b54a134aSDavid Howells #define EM(a, b) TRACE_DEFINE_ENUM(a);
526b54a134aSDavid Howells #define E_(a, b) TRACE_DEFINE_ENUM(a);
527b54a134aSDavid Howells 
52857af281eSDavid Howells rxrpc_abort_reasons;
529fa3492abSDavid Howells rxrpc_bundle_traces;
53015f661dcSDavid Howells rxrpc_call_poke_traces;
531b54a134aSDavid Howells rxrpc_call_traces;
532dc9fd093SDavid Howells rxrpc_client_traces;
533dc9fd093SDavid Howells rxrpc_congest_changes;
534dc9fd093SDavid Howells rxrpc_congest_modes;
535dc9fd093SDavid Howells rxrpc_conn_traces;
536dc9fd093SDavid Howells rxrpc_local_traces;
537dc9fd093SDavid Howells rxrpc_propose_ack_traces;
538b54a134aSDavid Howells rxrpc_receive_traces;
539b54a134aSDavid Howells rxrpc_recvmsg_traces;
5404d843be5SDavid Howells rxrpc_req_ack_traces;
541b54a134aSDavid Howells rxrpc_rtt_rx_traces;
542dc9fd093SDavid Howells rxrpc_rtt_tx_traces;
543f21e9348SDavid Howells rxrpc_sack_traces;
544dc9fd093SDavid Howells rxrpc_skb_traces;
545b54a134aSDavid Howells rxrpc_timer_traces;
5464764c0daSDavid Howells rxrpc_tx_points;
54702a19356SDavid Howells rxrpc_txbuf_traces;
548a4ea4c47SDavid Howells rxrpc_txqueue_traces;
549b54a134aSDavid Howells 
550b54a134aSDavid Howells /*
551b54a134aSDavid Howells  * Now redefine the EM() and E_() macros to map the enums to the strings that
552b54a134aSDavid Howells  * will be printed in the output.
553b54a134aSDavid Howells  */
554b54a134aSDavid Howells #undef EM
555b54a134aSDavid Howells #undef E_
556b54a134aSDavid Howells #define EM(a, b)	{ a, b },
557b54a134aSDavid Howells #define E_(a, b)	{ a, b }
558b54a134aSDavid Howells 
55909d2bf59SDavid Howells TRACE_EVENT(rxrpc_local,
56006d9532fSDavid Howells 	    TP_PROTO(unsigned int local_debug_id, enum rxrpc_local_trace op,
5610fde882fSDavid Howells 		     int ref, int usage),
56209d2bf59SDavid Howells 
5630fde882fSDavid Howells 	    TP_ARGS(local_debug_id, op, ref, usage),
56409d2bf59SDavid Howells 
56509d2bf59SDavid Howells 	    TP_STRUCT__entry(
56609d2bf59SDavid Howells 		    __field(unsigned int,	local)
56709d2bf59SDavid Howells 		    __field(int,		op)
5680fde882fSDavid Howells 		    __field(int,		ref)
56909d2bf59SDavid Howells 		    __field(int,		usage)
57009d2bf59SDavid Howells 			     ),
57109d2bf59SDavid Howells 
57209d2bf59SDavid Howells 	    TP_fast_assign(
57306d9532fSDavid Howells 		    __entry->local = local_debug_id;
57409d2bf59SDavid Howells 		    __entry->op = op;
5750fde882fSDavid Howells 		    __entry->ref = ref;
57609d2bf59SDavid Howells 		    __entry->usage = usage;
57709d2bf59SDavid Howells 			   ),
57809d2bf59SDavid Howells 
5790fde882fSDavid Howells 	    TP_printk("L=%08x %s r=%d u=%d",
58009d2bf59SDavid Howells 		      __entry->local,
58109d2bf59SDavid Howells 		      __print_symbolic(__entry->op, rxrpc_local_traces),
5820fde882fSDavid Howells 		      __entry->ref,
5830fde882fSDavid Howells 		      __entry->usage)
58409d2bf59SDavid Howells 	    );
58509d2bf59SDavid Howells 
5861159d4b4SDavid Howells TRACE_EVENT(rxrpc_peer,
58747c810a7SDavid Howells 	    TP_PROTO(unsigned int peer_debug_id, int ref, enum rxrpc_peer_trace why),
5881159d4b4SDavid Howells 
58947c810a7SDavid Howells 	    TP_ARGS(peer_debug_id, ref, why),
5901159d4b4SDavid Howells 
5911159d4b4SDavid Howells 	    TP_STRUCT__entry(
5921159d4b4SDavid Howells 		    __field(unsigned int,	peer)
59347c810a7SDavid Howells 		    __field(int,		ref)
594c838f1a7SDavid Howells 		    __field(enum rxrpc_peer_trace, why)
5951159d4b4SDavid Howells 			     ),
5961159d4b4SDavid Howells 
5971159d4b4SDavid Howells 	    TP_fast_assign(
59855f6c98eSDavid Howells 		    __entry->peer = peer_debug_id;
59947c810a7SDavid Howells 		    __entry->ref = ref;
60047c810a7SDavid Howells 		    __entry->why = why;
6011159d4b4SDavid Howells 			   ),
6021159d4b4SDavid Howells 
60347c810a7SDavid Howells 	    TP_printk("P=%08x %s r=%d",
6041159d4b4SDavid Howells 		      __entry->peer,
60547c810a7SDavid Howells 		      __print_symbolic(__entry->why, rxrpc_peer_traces),
60647c810a7SDavid Howells 		      __entry->ref)
6071159d4b4SDavid Howells 	    );
6081159d4b4SDavid Howells 
609fa3492abSDavid Howells TRACE_EVENT(rxrpc_bundle,
610fa3492abSDavid Howells 	    TP_PROTO(unsigned int bundle_debug_id, int ref, enum rxrpc_bundle_trace why),
611fa3492abSDavid Howells 
612fa3492abSDavid Howells 	    TP_ARGS(bundle_debug_id, ref, why),
613fa3492abSDavid Howells 
614fa3492abSDavid Howells 	    TP_STRUCT__entry(
615fa3492abSDavid Howells 		    __field(unsigned int,	bundle)
616fa3492abSDavid Howells 		    __field(int,		ref)
617fa3492abSDavid Howells 		    __field(int,		why)
618fa3492abSDavid Howells 			     ),
619fa3492abSDavid Howells 
620fa3492abSDavid Howells 	    TP_fast_assign(
621fa3492abSDavid Howells 		    __entry->bundle = bundle_debug_id;
622fa3492abSDavid Howells 		    __entry->ref = ref;
623fa3492abSDavid Howells 		    __entry->why = why;
624fa3492abSDavid Howells 			   ),
625fa3492abSDavid Howells 
626fa3492abSDavid Howells 	    TP_printk("CB=%08x %s r=%d",
627fa3492abSDavid Howells 		      __entry->bundle,
628fa3492abSDavid Howells 		      __print_symbolic(__entry->why, rxrpc_bundle_traces),
629fa3492abSDavid Howells 		      __entry->ref)
630fa3492abSDavid Howells 	    );
631fa3492abSDavid Howells 
632363deeabSDavid Howells TRACE_EVENT(rxrpc_conn,
6337fa25105SDavid Howells 	    TP_PROTO(unsigned int conn_debug_id, int ref, enum rxrpc_conn_trace why),
634363deeabSDavid Howells 
6357fa25105SDavid Howells 	    TP_ARGS(conn_debug_id, ref, why),
636363deeabSDavid Howells 
637363deeabSDavid Howells 	    TP_STRUCT__entry(
638a25e21f0SDavid Howells 		    __field(unsigned int,	conn)
6397fa25105SDavid Howells 		    __field(int,		ref)
6407fa25105SDavid Howells 		    __field(int,		why)
641363deeabSDavid Howells 			     ),
642363deeabSDavid Howells 
643363deeabSDavid Howells 	    TP_fast_assign(
6444c1295dcSDavid Howells 		    __entry->conn = conn_debug_id;
6457fa25105SDavid Howells 		    __entry->ref = ref;
6467fa25105SDavid Howells 		    __entry->why = why;
647363deeabSDavid Howells 			   ),
648363deeabSDavid Howells 
6497fa25105SDavid Howells 	    TP_printk("C=%08x %s r=%d",
650363deeabSDavid Howells 		      __entry->conn,
6517fa25105SDavid Howells 		      __print_symbolic(__entry->why, rxrpc_conn_traces),
6527fa25105SDavid Howells 		      __entry->ref)
653363deeabSDavid Howells 	    );
654363deeabSDavid Howells 
655363deeabSDavid Howells TRACE_EVENT(rxrpc_client,
656363deeabSDavid Howells 	    TP_PROTO(struct rxrpc_connection *conn, int channel,
657363deeabSDavid Howells 		     enum rxrpc_client_trace op),
658363deeabSDavid Howells 
659363deeabSDavid Howells 	    TP_ARGS(conn, channel, op),
660363deeabSDavid Howells 
661363deeabSDavid Howells 	    TP_STRUCT__entry(
662a25e21f0SDavid Howells 		    __field(unsigned int,		conn)
663363deeabSDavid Howells 		    __field(u32,			cid)
664363deeabSDavid Howells 		    __field(int,			channel)
665363deeabSDavid Howells 		    __field(int,			usage)
666363deeabSDavid Howells 		    __field(enum rxrpc_client_trace,	op)
667363deeabSDavid Howells 			     ),
668363deeabSDavid Howells 
669363deeabSDavid Howells 	    TP_fast_assign(
670245500d8SDavid Howells 		    __entry->conn = conn ? conn->debug_id : 0;
671363deeabSDavid Howells 		    __entry->channel = channel;
672a0575429SDavid Howells 		    __entry->usage = conn ? refcount_read(&conn->ref) : -2;
673363deeabSDavid Howells 		    __entry->op = op;
67496a9c425SDavid Howells 		    __entry->cid = conn ? conn->proto.cid : 0;
675363deeabSDavid Howells 			   ),
676363deeabSDavid Howells 
677245500d8SDavid Howells 	    TP_printk("C=%08x h=%2d %s i=%08x u=%d",
678363deeabSDavid Howells 		      __entry->conn,
679363deeabSDavid Howells 		      __entry->channel,
680b54a134aSDavid Howells 		      __print_symbolic(__entry->op, rxrpc_client_traces),
681363deeabSDavid Howells 		      __entry->cid,
682363deeabSDavid Howells 		      __entry->usage)
683363deeabSDavid Howells 	    );
684363deeabSDavid Howells 
685e34d4234SDavid Howells TRACE_EVENT(rxrpc_call,
686cb0fc0c9SDavid Howells 	    TP_PROTO(unsigned int call_debug_id, int ref, unsigned long aux,
687cb0fc0c9SDavid Howells 		     enum rxrpc_call_trace why),
688e34d4234SDavid Howells 
689cb0fc0c9SDavid Howells 	    TP_ARGS(call_debug_id, ref, aux, why),
690e34d4234SDavid Howells 
691e34d4234SDavid Howells 	    TP_STRUCT__entry(
692a25e21f0SDavid Howells 		    __field(unsigned int,	call)
693cb0fc0c9SDavid Howells 		    __field(int,		ref)
694cb0fc0c9SDavid Howells 		    __field(int,		why)
695cb0fc0c9SDavid Howells 		    __field(unsigned long,	aux)
696e34d4234SDavid Howells 			     ),
697e34d4234SDavid Howells 
698e34d4234SDavid Howells 	    TP_fast_assign(
69948c9e0ecSDavid Howells 		    __entry->call = call_debug_id;
700cb0fc0c9SDavid Howells 		    __entry->ref = ref;
701cb0fc0c9SDavid Howells 		    __entry->why = why;
702e34d4234SDavid Howells 		    __entry->aux = aux;
703e34d4234SDavid Howells 			   ),
704e34d4234SDavid Howells 
705cb0fc0c9SDavid Howells 	    TP_printk("c=%08x %s r=%d a=%lx",
706e34d4234SDavid Howells 		      __entry->call,
707cb0fc0c9SDavid Howells 		      __print_symbolic(__entry->why, rxrpc_call_traces),
708cb0fc0c9SDavid Howells 		      __entry->ref,
709e34d4234SDavid Howells 		      __entry->aux)
710e34d4234SDavid Howells 	    );
711e34d4234SDavid Howells 
712df844fd4SDavid Howells TRACE_EVENT(rxrpc_skb,
7139a36a6bcSDavid Howells 	    TP_PROTO(struct sk_buff *skb, int usage, int mod_count,
7149a36a6bcSDavid Howells 		     enum rxrpc_skb_trace why),
715df844fd4SDavid Howells 
7169a36a6bcSDavid Howells 	    TP_ARGS(skb, usage, mod_count, why),
717df844fd4SDavid Howells 
718df844fd4SDavid Howells 	    TP_STRUCT__entry(
719df844fd4SDavid Howells 		    __field(struct sk_buff *,		skb)
720df844fd4SDavid Howells 		    __field(int,			usage)
721df844fd4SDavid Howells 		    __field(int,			mod_count)
7229a36a6bcSDavid Howells 		    __field(enum rxrpc_skb_trace,	why)
723df844fd4SDavid Howells 			     ),
724df844fd4SDavid Howells 
725df844fd4SDavid Howells 	    TP_fast_assign(
726df844fd4SDavid Howells 		    __entry->skb = skb;
727df844fd4SDavid Howells 		    __entry->usage = usage;
728df844fd4SDavid Howells 		    __entry->mod_count = mod_count;
7299a36a6bcSDavid Howells 		    __entry->why = why;
730df844fd4SDavid Howells 			   ),
731df844fd4SDavid Howells 
7329a36a6bcSDavid Howells 	    TP_printk("s=%p Rx %s u=%d m=%d",
733df844fd4SDavid Howells 		      __entry->skb,
7349a36a6bcSDavid Howells 		      __print_symbolic(__entry->why, rxrpc_skb_traces),
735df844fd4SDavid Howells 		      __entry->usage,
7369a36a6bcSDavid Howells 		      __entry->mod_count)
737df844fd4SDavid Howells 	    );
738df844fd4SDavid Howells 
73949e19ec7SDavid Howells TRACE_EVENT(rxrpc_rx_packet,
74049e19ec7SDavid Howells 	    TP_PROTO(struct rxrpc_skb_priv *sp),
74149e19ec7SDavid Howells 
74249e19ec7SDavid Howells 	    TP_ARGS(sp),
74349e19ec7SDavid Howells 
74449e19ec7SDavid Howells 	    TP_STRUCT__entry(
74549e19ec7SDavid Howells 		    __field_struct(struct rxrpc_host_header,	hdr)
74649e19ec7SDavid Howells 			     ),
74749e19ec7SDavid Howells 
74849e19ec7SDavid Howells 	    TP_fast_assign(
74949e19ec7SDavid Howells 		    memcpy(&__entry->hdr, &sp->hdr, sizeof(__entry->hdr));
75049e19ec7SDavid Howells 			   ),
75149e19ec7SDavid Howells 
752a3868bfcSDavid Howells 	    TP_printk("%08x:%08x:%08x:%04x %08x %08x %02x %02x %s",
75349e19ec7SDavid Howells 		      __entry->hdr.epoch, __entry->hdr.cid,
75449e19ec7SDavid Howells 		      __entry->hdr.callNumber, __entry->hdr.serviceId,
75549e19ec7SDavid Howells 		      __entry->hdr.serial, __entry->hdr.seq,
75683836eb4SDavid Howells 		      __entry->hdr.securityIndex, __entry->hdr.flags,
75783836eb4SDavid Howells 		      __print_symbolic(__entry->hdr.type, rxrpc_pkts))
75849e19ec7SDavid Howells 	    );
75949e19ec7SDavid Howells 
76049e19ec7SDavid Howells TRACE_EVENT(rxrpc_rx_done,
76149e19ec7SDavid Howells 	    TP_PROTO(int result, int abort_code),
76249e19ec7SDavid Howells 
76349e19ec7SDavid Howells 	    TP_ARGS(result, abort_code),
76449e19ec7SDavid Howells 
76549e19ec7SDavid Howells 	    TP_STRUCT__entry(
76649e19ec7SDavid Howells 		    __field(int,	result)
76749e19ec7SDavid Howells 		    __field(int,	abort_code)
76849e19ec7SDavid Howells 			     ),
76949e19ec7SDavid Howells 
77049e19ec7SDavid Howells 	    TP_fast_assign(
77149e19ec7SDavid Howells 		    __entry->result = result;
77249e19ec7SDavid Howells 		    __entry->abort_code = abort_code;
77349e19ec7SDavid Howells 			   ),
77449e19ec7SDavid Howells 
77549e19ec7SDavid Howells 	    TP_printk("r=%d a=%d", __entry->result, __entry->abort_code)
77649e19ec7SDavid Howells 	    );
77749e19ec7SDavid Howells 
7785a42976dSDavid Howells TRACE_EVENT(rxrpc_abort,
77957af281eSDavid Howells 	    TP_PROTO(unsigned int call_nr, enum rxrpc_abort_reason why,
78057af281eSDavid Howells 		     u32 cid, u32 call_id, rxrpc_seq_t seq, int abort_code, int error),
7815a42976dSDavid Howells 
782a25e21f0SDavid Howells 	    TP_ARGS(call_nr, why, cid, call_id, seq, abort_code, error),
7835a42976dSDavid Howells 
7845a42976dSDavid Howells 	    TP_STRUCT__entry(
785a25e21f0SDavid Howells 		    __field(unsigned int,		call_nr)
78657af281eSDavid Howells 		    __field(enum rxrpc_abort_reason,	why)
7875a42976dSDavid Howells 		    __field(u32,			cid)
7885a42976dSDavid Howells 		    __field(u32,			call_id)
7895a42976dSDavid Howells 		    __field(rxrpc_seq_t,		seq)
7905a42976dSDavid Howells 		    __field(int,			abort_code)
7915a42976dSDavid Howells 		    __field(int,			error)
7925a42976dSDavid Howells 			     ),
7935a42976dSDavid Howells 
7945a42976dSDavid Howells 	    TP_fast_assign(
795a25e21f0SDavid Howells 		    __entry->call_nr = call_nr;
79657af281eSDavid Howells 		    __entry->why = why;
7975a42976dSDavid Howells 		    __entry->cid = cid;
7985a42976dSDavid Howells 		    __entry->call_id = call_id;
7995a42976dSDavid Howells 		    __entry->abort_code = abort_code;
8005a42976dSDavid Howells 		    __entry->error = error;
8015a42976dSDavid Howells 		    __entry->seq = seq;
8025a42976dSDavid Howells 			   ),
8035a42976dSDavid Howells 
804a25e21f0SDavid Howells 	    TP_printk("c=%08x %08x:%08x s=%u a=%d e=%d %s",
805a25e21f0SDavid Howells 		      __entry->call_nr,
8065a42976dSDavid Howells 		      __entry->cid, __entry->call_id, __entry->seq,
80757af281eSDavid Howells 		      __entry->abort_code, __entry->error,
80857af281eSDavid Howells 		      __print_symbolic(__entry->why, rxrpc_abort_reasons))
8095a42976dSDavid Howells 	    );
8105a42976dSDavid Howells 
8111bae5d22SDavid Howells TRACE_EVENT(rxrpc_call_complete,
8121bae5d22SDavid Howells 	    TP_PROTO(struct rxrpc_call *call),
8131bae5d22SDavid Howells 
8141bae5d22SDavid Howells 	    TP_ARGS(call),
8151bae5d22SDavid Howells 
8161bae5d22SDavid Howells 	    TP_STRUCT__entry(
8171bae5d22SDavid Howells 		    __field(unsigned int,		call)
8181bae5d22SDavid Howells 		    __field(enum rxrpc_call_completion,	compl)
8191bae5d22SDavid Howells 		    __field(int,			error)
8201bae5d22SDavid Howells 		    __field(u32,			abort_code)
8211bae5d22SDavid Howells 			     ),
8221bae5d22SDavid Howells 
8231bae5d22SDavid Howells 	    TP_fast_assign(
8241bae5d22SDavid Howells 		    __entry->call = call->debug_id;
8251bae5d22SDavid Howells 		    __entry->compl = call->completion;
8261bae5d22SDavid Howells 		    __entry->error = call->error;
8271bae5d22SDavid Howells 		    __entry->abort_code = call->abort_code;
8281bae5d22SDavid Howells 			   ),
8291bae5d22SDavid Howells 
8301bae5d22SDavid Howells 	    TP_printk("c=%08x %s r=%d ac=%d",
8311bae5d22SDavid Howells 		      __entry->call,
8321bae5d22SDavid Howells 		      __print_symbolic(__entry->compl, rxrpc_completions),
8331bae5d22SDavid Howells 		      __entry->error,
8341bae5d22SDavid Howells 		      __entry->abort_code)
8351bae5d22SDavid Howells 	    );
8361bae5d22SDavid Howells 
837a4ea4c47SDavid Howells TRACE_EVENT(rxrpc_txqueue,
838a4ea4c47SDavid Howells 	    TP_PROTO(struct rxrpc_call *call, enum rxrpc_txqueue_trace why),
839a124fe3eSDavid Howells 
840a124fe3eSDavid Howells 	    TP_ARGS(call, why),
841a124fe3eSDavid Howells 
842a124fe3eSDavid Howells 	    TP_STRUCT__entry(
843a25e21f0SDavid Howells 		    __field(unsigned int,		call)
844a4ea4c47SDavid Howells 		    __field(enum rxrpc_txqueue_trace,	why)
845a4ea4c47SDavid Howells 		    __field(rxrpc_seq_t,		acks_hard_ack)
846a4ea4c47SDavid Howells 		    __field(rxrpc_seq_t,		tx_bottom)
847a124fe3eSDavid Howells 		    __field(rxrpc_seq_t,		tx_top)
848cf37b598SDavid Howells 		    __field(rxrpc_seq_t,		tx_prepared)
849b1d9f7fdSDavid Howells 		    __field(int,			tx_winsize)
850a124fe3eSDavid Howells 			     ),
851a124fe3eSDavid Howells 
852a124fe3eSDavid Howells 	    TP_fast_assign(
853a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
854a124fe3eSDavid Howells 		    __entry->why = why;
855a4ea4c47SDavid Howells 		    __entry->acks_hard_ack = call->acks_hard_ack;
856a4ea4c47SDavid Howells 		    __entry->tx_bottom = call->tx_bottom;
857a124fe3eSDavid Howells 		    __entry->tx_top = call->tx_top;
858cf37b598SDavid Howells 		    __entry->tx_prepared = call->tx_prepared;
859b1d9f7fdSDavid Howells 		    __entry->tx_winsize = call->tx_winsize;
860a124fe3eSDavid Howells 			   ),
861a124fe3eSDavid Howells 
862cf37b598SDavid Howells 	    TP_printk("c=%08x %s f=%08x h=%08x n=%u/%u/%u/%u",
863a124fe3eSDavid Howells 		      __entry->call,
864a4ea4c47SDavid Howells 		      __print_symbolic(__entry->why, rxrpc_txqueue_traces),
865a4ea4c47SDavid Howells 		      __entry->tx_bottom,
866a4ea4c47SDavid Howells 		      __entry->acks_hard_ack,
867a4ea4c47SDavid Howells 		      __entry->tx_top - __entry->tx_bottom,
868a4ea4c47SDavid Howells 		      __entry->tx_top - __entry->acks_hard_ack,
869cf37b598SDavid Howells 		      __entry->tx_prepared - __entry->tx_bottom,
870b1d9f7fdSDavid Howells 		      __entry->tx_winsize)
871a124fe3eSDavid Howells 	    );
872a124fe3eSDavid Howells 
873b1d9f7fdSDavid Howells TRACE_EVENT(rxrpc_rx_data,
8744764c0daSDavid Howells 	    TP_PROTO(unsigned int call, rxrpc_seq_t seq,
875d4d02d8bSDavid Howells 		     rxrpc_serial_t serial, u8 flags),
876ec71eb9aSDavid Howells 
877d4d02d8bSDavid Howells 	    TP_ARGS(call, seq, serial, flags),
878ec71eb9aSDavid Howells 
879ec71eb9aSDavid Howells 	    TP_STRUCT__entry(
880a25e21f0SDavid Howells 		    __field(unsigned int,	call)
881b1d9f7fdSDavid Howells 		    __field(rxrpc_seq_t,	seq)
882b1d9f7fdSDavid Howells 		    __field(rxrpc_serial_t,	serial)
883b1d9f7fdSDavid Howells 		    __field(u8,			flags)
884b1d9f7fdSDavid Howells 			     ),
885b1d9f7fdSDavid Howells 
886b1d9f7fdSDavid Howells 	    TP_fast_assign(
8874764c0daSDavid Howells 		    __entry->call = call;
888b1d9f7fdSDavid Howells 		    __entry->seq = seq;
889b1d9f7fdSDavid Howells 		    __entry->serial = serial;
890b1d9f7fdSDavid Howells 		    __entry->flags = flags;
891b1d9f7fdSDavid Howells 			   ),
892b1d9f7fdSDavid Howells 
893d4d02d8bSDavid Howells 	    TP_printk("c=%08x DATA %08x q=%08x fl=%02x",
894b1d9f7fdSDavid Howells 		      __entry->call,
895b1d9f7fdSDavid Howells 		      __entry->serial,
896b1d9f7fdSDavid Howells 		      __entry->seq,
897d4d02d8bSDavid Howells 		      __entry->flags)
898b1d9f7fdSDavid Howells 	    );
899b1d9f7fdSDavid Howells 
900b1d9f7fdSDavid Howells TRACE_EVENT(rxrpc_rx_ack,
901b1d9f7fdSDavid Howells 	    TP_PROTO(struct rxrpc_call *call,
902b1d9f7fdSDavid Howells 		     rxrpc_serial_t serial, rxrpc_serial_t ack_serial,
903b1d9f7fdSDavid Howells 		     rxrpc_seq_t first, rxrpc_seq_t prev, u8 reason, u8 n_acks),
904b1d9f7fdSDavid Howells 
905b1d9f7fdSDavid Howells 	    TP_ARGS(call, serial, ack_serial, first, prev, reason, n_acks),
906b1d9f7fdSDavid Howells 
907b1d9f7fdSDavid Howells 	    TP_STRUCT__entry(
908a25e21f0SDavid Howells 		    __field(unsigned int,	call)
909b1d9f7fdSDavid Howells 		    __field(rxrpc_serial_t,	serial)
910b1d9f7fdSDavid Howells 		    __field(rxrpc_serial_t,	ack_serial)
911ec71eb9aSDavid Howells 		    __field(rxrpc_seq_t,	first)
912b1d9f7fdSDavid Howells 		    __field(rxrpc_seq_t,	prev)
913ec71eb9aSDavid Howells 		    __field(u8,			reason)
914ec71eb9aSDavid Howells 		    __field(u8,			n_acks)
915ec71eb9aSDavid Howells 			     ),
916ec71eb9aSDavid Howells 
917ec71eb9aSDavid Howells 	    TP_fast_assign(
918a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
919b1d9f7fdSDavid Howells 		    __entry->serial = serial;
920b1d9f7fdSDavid Howells 		    __entry->ack_serial = ack_serial;
921ec71eb9aSDavid Howells 		    __entry->first = first;
922b1d9f7fdSDavid Howells 		    __entry->prev = prev;
923ec71eb9aSDavid Howells 		    __entry->reason = reason;
924ec71eb9aSDavid Howells 		    __entry->n_acks = n_acks;
925ec71eb9aSDavid Howells 			   ),
926ec71eb9aSDavid Howells 
927a25e21f0SDavid Howells 	    TP_printk("c=%08x %08x %s r=%08x f=%08x p=%08x n=%u",
928ec71eb9aSDavid Howells 		      __entry->call,
929b1d9f7fdSDavid Howells 		      __entry->serial,
930b54a134aSDavid Howells 		      __print_symbolic(__entry->reason, rxrpc_ack_names),
931b1d9f7fdSDavid Howells 		      __entry->ack_serial,
932ec71eb9aSDavid Howells 		      __entry->first,
933b1d9f7fdSDavid Howells 		      __entry->prev,
934ec71eb9aSDavid Howells 		      __entry->n_acks)
935ec71eb9aSDavid Howells 	    );
936ec71eb9aSDavid Howells 
937005ede28SDavid Howells TRACE_EVENT(rxrpc_rx_abort,
938005ede28SDavid Howells 	    TP_PROTO(struct rxrpc_call *call, rxrpc_serial_t serial,
939005ede28SDavid Howells 		     u32 abort_code),
940005ede28SDavid Howells 
941005ede28SDavid Howells 	    TP_ARGS(call, serial, abort_code),
942005ede28SDavid Howells 
943005ede28SDavid Howells 	    TP_STRUCT__entry(
944a25e21f0SDavid Howells 		    __field(unsigned int,	call)
945005ede28SDavid Howells 		    __field(rxrpc_serial_t,	serial)
946005ede28SDavid Howells 		    __field(u32,		abort_code)
947005ede28SDavid Howells 			     ),
948005ede28SDavid Howells 
949005ede28SDavid Howells 	    TP_fast_assign(
950a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
951005ede28SDavid Howells 		    __entry->serial = serial;
952005ede28SDavid Howells 		    __entry->abort_code = abort_code;
953005ede28SDavid Howells 			   ),
954005ede28SDavid Howells 
955a25e21f0SDavid Howells 	    TP_printk("c=%08x ABORT %08x ac=%d",
956005ede28SDavid Howells 		      __entry->call,
957005ede28SDavid Howells 		      __entry->serial,
958005ede28SDavid Howells 		      __entry->abort_code)
959005ede28SDavid Howells 	    );
960005ede28SDavid Howells 
9612ebdb26eSDavid Howells TRACE_EVENT(rxrpc_rx_challenge,
9622ebdb26eSDavid Howells 	    TP_PROTO(struct rxrpc_connection *conn, rxrpc_serial_t serial,
9632ebdb26eSDavid Howells 		     u32 version, u32 nonce, u32 min_level),
9642ebdb26eSDavid Howells 
9652ebdb26eSDavid Howells 	    TP_ARGS(conn, serial, version, nonce, min_level),
9662ebdb26eSDavid Howells 
9672ebdb26eSDavid Howells 	    TP_STRUCT__entry(
9682ebdb26eSDavid Howells 		    __field(unsigned int,	conn)
9692ebdb26eSDavid Howells 		    __field(rxrpc_serial_t,	serial)
9702ebdb26eSDavid Howells 		    __field(u32,		version)
9712ebdb26eSDavid Howells 		    __field(u32,		nonce)
9722ebdb26eSDavid Howells 		    __field(u32,		min_level)
9732ebdb26eSDavid Howells 			     ),
9742ebdb26eSDavid Howells 
9752ebdb26eSDavid Howells 	    TP_fast_assign(
9762ebdb26eSDavid Howells 		    __entry->conn = conn->debug_id;
9772ebdb26eSDavid Howells 		    __entry->serial = serial;
9782ebdb26eSDavid Howells 		    __entry->version = version;
9792ebdb26eSDavid Howells 		    __entry->nonce = nonce;
9802ebdb26eSDavid Howells 		    __entry->min_level = min_level;
9812ebdb26eSDavid Howells 			   ),
9822ebdb26eSDavid Howells 
9832ebdb26eSDavid Howells 	    TP_printk("C=%08x CHALLENGE %08x v=%x n=%x ml=%x",
9842ebdb26eSDavid Howells 		      __entry->conn,
9852ebdb26eSDavid Howells 		      __entry->serial,
9862ebdb26eSDavid Howells 		      __entry->version,
9872ebdb26eSDavid Howells 		      __entry->nonce,
9882ebdb26eSDavid Howells 		      __entry->min_level)
9892ebdb26eSDavid Howells 	    );
9902ebdb26eSDavid Howells 
9912ebdb26eSDavid Howells TRACE_EVENT(rxrpc_rx_response,
9922ebdb26eSDavid Howells 	    TP_PROTO(struct rxrpc_connection *conn, rxrpc_serial_t serial,
9932ebdb26eSDavid Howells 		     u32 version, u32 kvno, u32 ticket_len),
9942ebdb26eSDavid Howells 
9952ebdb26eSDavid Howells 	    TP_ARGS(conn, serial, version, kvno, ticket_len),
9962ebdb26eSDavid Howells 
9972ebdb26eSDavid Howells 	    TP_STRUCT__entry(
9982ebdb26eSDavid Howells 		    __field(unsigned int,	conn)
9992ebdb26eSDavid Howells 		    __field(rxrpc_serial_t,	serial)
10002ebdb26eSDavid Howells 		    __field(u32,		version)
10012ebdb26eSDavid Howells 		    __field(u32,		kvno)
10022ebdb26eSDavid Howells 		    __field(u32,		ticket_len)
10032ebdb26eSDavid Howells 			     ),
10042ebdb26eSDavid Howells 
10052ebdb26eSDavid Howells 	    TP_fast_assign(
10062ebdb26eSDavid Howells 		    __entry->conn = conn->debug_id;
10072ebdb26eSDavid Howells 		    __entry->serial = serial;
10082ebdb26eSDavid Howells 		    __entry->version = version;
10092ebdb26eSDavid Howells 		    __entry->kvno = kvno;
10102ebdb26eSDavid Howells 		    __entry->ticket_len = ticket_len;
10112ebdb26eSDavid Howells 			   ),
10122ebdb26eSDavid Howells 
10132ebdb26eSDavid Howells 	    TP_printk("C=%08x RESPONSE %08x v=%x kvno=%x tl=%x",
10142ebdb26eSDavid Howells 		      __entry->conn,
10152ebdb26eSDavid Howells 		      __entry->serial,
10162ebdb26eSDavid Howells 		      __entry->version,
10172ebdb26eSDavid Howells 		      __entry->kvno,
10182ebdb26eSDavid Howells 		      __entry->ticket_len)
10192ebdb26eSDavid Howells 	    );
10202ebdb26eSDavid Howells 
1021740586d2SDavid Howells TRACE_EVENT(rxrpc_rx_rwind_change,
1022740586d2SDavid Howells 	    TP_PROTO(struct rxrpc_call *call, rxrpc_serial_t serial,
1023740586d2SDavid Howells 		     u32 rwind, bool wake),
1024740586d2SDavid Howells 
1025740586d2SDavid Howells 	    TP_ARGS(call, serial, rwind, wake),
1026740586d2SDavid Howells 
1027740586d2SDavid Howells 	    TP_STRUCT__entry(
1028a25e21f0SDavid Howells 		    __field(unsigned int,	call)
1029740586d2SDavid Howells 		    __field(rxrpc_serial_t,	serial)
1030740586d2SDavid Howells 		    __field(u32,		rwind)
1031740586d2SDavid Howells 		    __field(bool,		wake)
1032740586d2SDavid Howells 			     ),
1033740586d2SDavid Howells 
1034740586d2SDavid Howells 	    TP_fast_assign(
1035a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
1036740586d2SDavid Howells 		    __entry->serial = serial;
1037740586d2SDavid Howells 		    __entry->rwind = rwind;
1038740586d2SDavid Howells 		    __entry->wake = wake;
1039740586d2SDavid Howells 			   ),
1040740586d2SDavid Howells 
1041a25e21f0SDavid Howells 	    TP_printk("c=%08x %08x rw=%u%s",
1042740586d2SDavid Howells 		      __entry->call,
1043740586d2SDavid Howells 		      __entry->serial,
1044740586d2SDavid Howells 		      __entry->rwind,
1045740586d2SDavid Howells 		      __entry->wake ? " wake" : "")
1046740586d2SDavid Howells 	    );
1047740586d2SDavid Howells 
10484764c0daSDavid Howells TRACE_EVENT(rxrpc_tx_packet,
10494764c0daSDavid Howells 	    TP_PROTO(unsigned int call_id, struct rxrpc_wire_header *whdr,
10504764c0daSDavid Howells 		     enum rxrpc_tx_point where),
10514764c0daSDavid Howells 
10524764c0daSDavid Howells 	    TP_ARGS(call_id, whdr, where),
10534764c0daSDavid Howells 
10544764c0daSDavid Howells 	    TP_STRUCT__entry(
10554764c0daSDavid Howells 		    __field(unsigned int,			call)
10564764c0daSDavid Howells 		    __field(enum rxrpc_tx_point,		where)
10574764c0daSDavid Howells 		    __field_struct(struct rxrpc_wire_header,	whdr)
10584764c0daSDavid Howells 			     ),
10594764c0daSDavid Howells 
10604764c0daSDavid Howells 	    TP_fast_assign(
10614764c0daSDavid Howells 		    __entry->call = call_id;
10624764c0daSDavid Howells 		    memcpy(&__entry->whdr, whdr, sizeof(__entry->whdr));
10634e2abd3cSDavid Howells 		    __entry->where = where;
10644764c0daSDavid Howells 			   ),
10654764c0daSDavid Howells 
10664764c0daSDavid Howells 	    TP_printk("c=%08x %08x:%08x:%08x:%04x %08x %08x %02x %02x %s %s",
10674764c0daSDavid Howells 		      __entry->call,
10684764c0daSDavid Howells 		      ntohl(__entry->whdr.epoch),
10694764c0daSDavid Howells 		      ntohl(__entry->whdr.cid),
10704764c0daSDavid Howells 		      ntohl(__entry->whdr.callNumber),
10714764c0daSDavid Howells 		      ntohs(__entry->whdr.serviceId),
10724764c0daSDavid Howells 		      ntohl(__entry->whdr.serial),
10734764c0daSDavid Howells 		      ntohl(__entry->whdr.seq),
10744764c0daSDavid Howells 		      __entry->whdr.type, __entry->whdr.flags,
10754764c0daSDavid Howells 		      __entry->whdr.type <= 15 ?
10764764c0daSDavid Howells 		      __print_symbolic(__entry->whdr.type, rxrpc_pkts) : "?UNK",
10774764c0daSDavid Howells 		      __print_symbolic(__entry->where, rxrpc_tx_points))
10784764c0daSDavid Howells 	    );
10794764c0daSDavid Howells 
1080be832aecSDavid Howells TRACE_EVENT(rxrpc_tx_data,
1081be832aecSDavid Howells 	    TP_PROTO(struct rxrpc_call *call, rxrpc_seq_t seq,
1082a1767077SDavid Howells 		     rxrpc_serial_t serial, u8 flags, bool retrans, bool lose),
1083f3639df2SDavid Howells 
1084a1767077SDavid Howells 	    TP_ARGS(call, seq, serial, flags, retrans, lose),
1085f3639df2SDavid Howells 
1086f3639df2SDavid Howells 	    TP_STRUCT__entry(
1087a25e21f0SDavid Howells 		    __field(unsigned int,	call)
1088be832aecSDavid Howells 		    __field(rxrpc_seq_t,	seq)
1089f3639df2SDavid Howells 		    __field(rxrpc_serial_t,	serial)
10904764c0daSDavid Howells 		    __field(u32,		cid)
10914764c0daSDavid Howells 		    __field(u32,		call_id)
1092be832aecSDavid Howells 		    __field(u8,			flags)
1093a1767077SDavid Howells 		    __field(bool,		retrans)
1094be832aecSDavid Howells 		    __field(bool,		lose)
1095be832aecSDavid Howells 			     ),
1096be832aecSDavid Howells 
1097be832aecSDavid Howells 	    TP_fast_assign(
1098a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
10994764c0daSDavid Howells 		    __entry->cid = call->cid;
11004764c0daSDavid Howells 		    __entry->call_id = call->call_id;
1101be832aecSDavid Howells 		    __entry->seq = seq;
1102be832aecSDavid Howells 		    __entry->serial = serial;
1103be832aecSDavid Howells 		    __entry->flags = flags;
1104a1767077SDavid Howells 		    __entry->retrans = retrans;
1105be832aecSDavid Howells 		    __entry->lose = lose;
1106be832aecSDavid Howells 			   ),
1107be832aecSDavid Howells 
11084764c0daSDavid Howells 	    TP_printk("c=%08x DATA %08x:%08x %08x q=%08x fl=%02x%s%s",
1109be832aecSDavid Howells 		      __entry->call,
11104764c0daSDavid Howells 		      __entry->cid,
11114764c0daSDavid Howells 		      __entry->call_id,
1112be832aecSDavid Howells 		      __entry->serial,
1113be832aecSDavid Howells 		      __entry->seq,
1114be832aecSDavid Howells 		      __entry->flags,
1115265a44bbSDavid Howells 		      __entry->retrans ? " *RETRANS*" : "",
1116be832aecSDavid Howells 		      __entry->lose ? " *LOSE*" : "")
1117be832aecSDavid Howells 	    );
1118be832aecSDavid Howells 
1119be832aecSDavid Howells TRACE_EVENT(rxrpc_tx_ack,
11204764c0daSDavid Howells 	    TP_PROTO(unsigned int call, rxrpc_serial_t serial,
1121be832aecSDavid Howells 		     rxrpc_seq_t ack_first, rxrpc_serial_t ack_serial,
1122f789bff2SDavid Howells 		     u8 reason, u8 n_acks, u16 rwind),
1123be832aecSDavid Howells 
1124f789bff2SDavid Howells 	    TP_ARGS(call, serial, ack_first, ack_serial, reason, n_acks, rwind),
1125be832aecSDavid Howells 
1126be832aecSDavid Howells 	    TP_STRUCT__entry(
1127a25e21f0SDavid Howells 		    __field(unsigned int,	call)
1128be832aecSDavid Howells 		    __field(rxrpc_serial_t,	serial)
1129be832aecSDavid Howells 		    __field(rxrpc_seq_t,	ack_first)
1130be832aecSDavid Howells 		    __field(rxrpc_serial_t,	ack_serial)
1131f3639df2SDavid Howells 		    __field(u8,			reason)
1132f3639df2SDavid Howells 		    __field(u8,			n_acks)
1133f789bff2SDavid Howells 		    __field(u16,		rwind)
1134f3639df2SDavid Howells 			     ),
1135f3639df2SDavid Howells 
1136f3639df2SDavid Howells 	    TP_fast_assign(
11374764c0daSDavid Howells 		    __entry->call = call;
1138f3639df2SDavid Howells 		    __entry->serial = serial;
1139be832aecSDavid Howells 		    __entry->ack_first = ack_first;
1140be832aecSDavid Howells 		    __entry->ack_serial = ack_serial;
1141f3639df2SDavid Howells 		    __entry->reason = reason;
1142f3639df2SDavid Howells 		    __entry->n_acks = n_acks;
1143f789bff2SDavid Howells 		    __entry->rwind = rwind;
1144f3639df2SDavid Howells 			   ),
1145f3639df2SDavid Howells 
1146f789bff2SDavid Howells 	    TP_printk(" c=%08x ACK  %08x %s f=%08x r=%08x n=%u rw=%u",
1147f3639df2SDavid Howells 		      __entry->call,
1148f3639df2SDavid Howells 		      __entry->serial,
1149b54a134aSDavid Howells 		      __print_symbolic(__entry->reason, rxrpc_ack_names),
1150be832aecSDavid Howells 		      __entry->ack_first,
1151be832aecSDavid Howells 		      __entry->ack_serial,
1152f789bff2SDavid Howells 		      __entry->n_acks,
1153f789bff2SDavid Howells 		      __entry->rwind)
1154f3639df2SDavid Howells 	    );
1155f3639df2SDavid Howells 
115658dc63c9SDavid Howells TRACE_EVENT(rxrpc_receive,
115758dc63c9SDavid Howells 	    TP_PROTO(struct rxrpc_call *call, enum rxrpc_receive_trace why,
115858dc63c9SDavid Howells 		     rxrpc_serial_t serial, rxrpc_seq_t seq),
115958dc63c9SDavid Howells 
116058dc63c9SDavid Howells 	    TP_ARGS(call, why, serial, seq),
116158dc63c9SDavid Howells 
116258dc63c9SDavid Howells 	    TP_STRUCT__entry(
1163a25e21f0SDavid Howells 		    __field(unsigned int,		call)
116458dc63c9SDavid Howells 		    __field(enum rxrpc_receive_trace,	why)
116558dc63c9SDavid Howells 		    __field(rxrpc_serial_t,		serial)
116658dc63c9SDavid Howells 		    __field(rxrpc_seq_t,		seq)
11675bbf9533SDavid Howells 		    __field(rxrpc_seq_t,		window)
11685bbf9533SDavid Howells 		    __field(rxrpc_seq_t,		wtop)
116958dc63c9SDavid Howells 			     ),
117058dc63c9SDavid Howells 
117158dc63c9SDavid Howells 	    TP_fast_assign(
1172a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
117358dc63c9SDavid Howells 		    __entry->why = why;
117458dc63c9SDavid Howells 		    __entry->serial = serial;
117558dc63c9SDavid Howells 		    __entry->seq = seq;
11765bbf9533SDavid Howells 		    __entry->window = call->ackr_window;
11775bbf9533SDavid Howells 		    __entry->wtop = call->ackr_wtop;
117858dc63c9SDavid Howells 			   ),
117958dc63c9SDavid Howells 
1180a25e21f0SDavid Howells 	    TP_printk("c=%08x %s r=%08x q=%08x w=%08x-%08x",
118158dc63c9SDavid Howells 		      __entry->call,
1182b54a134aSDavid Howells 		      __print_symbolic(__entry->why, rxrpc_receive_traces),
118358dc63c9SDavid Howells 		      __entry->serial,
118458dc63c9SDavid Howells 		      __entry->seq,
11855bbf9533SDavid Howells 		      __entry->window,
11865bbf9533SDavid Howells 		      __entry->wtop)
118758dc63c9SDavid Howells 	    );
118858dc63c9SDavid Howells 
118984997905SDavid Howells TRACE_EVENT(rxrpc_recvmsg,
11900e50d999SDavid Howells 	    TP_PROTO(unsigned int call_debug_id, enum rxrpc_recvmsg_trace why,
1191faf92e8dSDavid Howells 		     int ret),
1192faf92e8dSDavid Howells 
11930e50d999SDavid Howells 	    TP_ARGS(call_debug_id, why, ret),
1194faf92e8dSDavid Howells 
1195faf92e8dSDavid Howells 	    TP_STRUCT__entry(
1196faf92e8dSDavid Howells 		    __field(unsigned int,		call)
1197faf92e8dSDavid Howells 		    __field(enum rxrpc_recvmsg_trace,	why)
1198faf92e8dSDavid Howells 		    __field(int,			ret)
1199faf92e8dSDavid Howells 			     ),
1200faf92e8dSDavid Howells 
1201faf92e8dSDavid Howells 	    TP_fast_assign(
12020e50d999SDavid Howells 		    __entry->call = call_debug_id;
1203faf92e8dSDavid Howells 		    __entry->why = why;
1204faf92e8dSDavid Howells 		    __entry->ret = ret;
1205faf92e8dSDavid Howells 			   ),
1206faf92e8dSDavid Howells 
1207faf92e8dSDavid Howells 	    TP_printk("c=%08x %s ret=%d",
1208faf92e8dSDavid Howells 		      __entry->call,
1209faf92e8dSDavid Howells 		      __print_symbolic(__entry->why, rxrpc_recvmsg_traces),
1210faf92e8dSDavid Howells 		      __entry->ret)
1211faf92e8dSDavid Howells 	    );
1212faf92e8dSDavid Howells 
1213faf92e8dSDavid Howells TRACE_EVENT(rxrpc_recvdata,
1214faf92e8dSDavid Howells 	    TP_PROTO(struct rxrpc_call *call, enum rxrpc_recvmsg_trace why,
121584997905SDavid Howells 		     rxrpc_seq_t seq, unsigned int offset, unsigned int len,
121684997905SDavid Howells 		     int ret),
121784997905SDavid Howells 
121884997905SDavid Howells 	    TP_ARGS(call, why, seq, offset, len, ret),
121984997905SDavid Howells 
122084997905SDavid Howells 	    TP_STRUCT__entry(
1221a25e21f0SDavid Howells 		    __field(unsigned int,		call)
122284997905SDavid Howells 		    __field(enum rxrpc_recvmsg_trace,	why)
122384997905SDavid Howells 		    __field(rxrpc_seq_t,		seq)
122484997905SDavid Howells 		    __field(unsigned int,		offset)
122584997905SDavid Howells 		    __field(unsigned int,		len)
122684997905SDavid Howells 		    __field(int,			ret)
122784997905SDavid Howells 			     ),
122884997905SDavid Howells 
122984997905SDavid Howells 	    TP_fast_assign(
1230db9b2e0aSDavid Howells 		    __entry->call = call ? call->debug_id : 0;
123184997905SDavid Howells 		    __entry->why = why;
123284997905SDavid Howells 		    __entry->seq = seq;
123384997905SDavid Howells 		    __entry->offset = offset;
123484997905SDavid Howells 		    __entry->len = len;
123584997905SDavid Howells 		    __entry->ret = ret;
123684997905SDavid Howells 			   ),
123784997905SDavid Howells 
1238a25e21f0SDavid Howells 	    TP_printk("c=%08x %s q=%08x o=%u l=%u ret=%d",
123984997905SDavid Howells 		      __entry->call,
1240b54a134aSDavid Howells 		      __print_symbolic(__entry->why, rxrpc_recvmsg_traces),
124184997905SDavid Howells 		      __entry->seq,
124284997905SDavid Howells 		      __entry->offset,
124384997905SDavid Howells 		      __entry->len,
124484997905SDavid Howells 		      __entry->ret)
124584997905SDavid Howells 	    );
124684997905SDavid Howells 
1247cf1a6474SDavid Howells TRACE_EVENT(rxrpc_rtt_tx,
1248cf1a6474SDavid Howells 	    TP_PROTO(struct rxrpc_call *call, enum rxrpc_rtt_tx_trace why,
12494700c4d8SDavid Howells 		     int slot, rxrpc_serial_t send_serial),
1250cf1a6474SDavid Howells 
12514700c4d8SDavid Howells 	    TP_ARGS(call, why, slot, send_serial),
1252cf1a6474SDavid Howells 
1253cf1a6474SDavid Howells 	    TP_STRUCT__entry(
1254a25e21f0SDavid Howells 		    __field(unsigned int,		call)
1255cf1a6474SDavid Howells 		    __field(enum rxrpc_rtt_tx_trace,	why)
12564700c4d8SDavid Howells 		    __field(int,			slot)
1257cf1a6474SDavid Howells 		    __field(rxrpc_serial_t,		send_serial)
1258cf1a6474SDavid Howells 			     ),
1259cf1a6474SDavid Howells 
1260cf1a6474SDavid Howells 	    TP_fast_assign(
1261a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
1262cf1a6474SDavid Howells 		    __entry->why = why;
12634700c4d8SDavid Howells 		    __entry->slot = slot;
1264cf1a6474SDavid Howells 		    __entry->send_serial = send_serial;
1265cf1a6474SDavid Howells 			   ),
1266cf1a6474SDavid Howells 
12674700c4d8SDavid Howells 	    TP_printk("c=%08x [%d] %s sr=%08x",
1268cf1a6474SDavid Howells 		      __entry->call,
12694700c4d8SDavid Howells 		      __entry->slot,
1270b54a134aSDavid Howells 		      __print_symbolic(__entry->why, rxrpc_rtt_tx_traces),
1271cf1a6474SDavid Howells 		      __entry->send_serial)
1272cf1a6474SDavid Howells 	    );
1273cf1a6474SDavid Howells 
1274cf1a6474SDavid Howells TRACE_EVENT(rxrpc_rtt_rx,
1275cf1a6474SDavid Howells 	    TP_PROTO(struct rxrpc_call *call, enum rxrpc_rtt_rx_trace why,
12764700c4d8SDavid Howells 		     int slot,
1277cf1a6474SDavid Howells 		     rxrpc_serial_t send_serial, rxrpc_serial_t resp_serial,
1278c410bf01SDavid Howells 		     u32 rtt, u32 rto),
1279cf1a6474SDavid Howells 
12804700c4d8SDavid Howells 	    TP_ARGS(call, why, slot, send_serial, resp_serial, rtt, rto),
1281cf1a6474SDavid Howells 
1282cf1a6474SDavid Howells 	    TP_STRUCT__entry(
1283a25e21f0SDavid Howells 		    __field(unsigned int,		call)
1284cf1a6474SDavid Howells 		    __field(enum rxrpc_rtt_rx_trace,	why)
12854700c4d8SDavid Howells 		    __field(int,			slot)
1286cf1a6474SDavid Howells 		    __field(rxrpc_serial_t,		send_serial)
1287cf1a6474SDavid Howells 		    __field(rxrpc_serial_t,		resp_serial)
1288c410bf01SDavid Howells 		    __field(u32,			rtt)
1289c410bf01SDavid Howells 		    __field(u32,			rto)
1290cf1a6474SDavid Howells 			     ),
1291cf1a6474SDavid Howells 
1292cf1a6474SDavid Howells 	    TP_fast_assign(
1293a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
1294cf1a6474SDavid Howells 		    __entry->why = why;
12954700c4d8SDavid Howells 		    __entry->slot = slot;
1296cf1a6474SDavid Howells 		    __entry->send_serial = send_serial;
1297cf1a6474SDavid Howells 		    __entry->resp_serial = resp_serial;
1298cf1a6474SDavid Howells 		    __entry->rtt = rtt;
1299c410bf01SDavid Howells 		    __entry->rto = rto;
1300cf1a6474SDavid Howells 			   ),
1301cf1a6474SDavid Howells 
13024700c4d8SDavid Howells 	    TP_printk("c=%08x [%d] %s sr=%08x rr=%08x rtt=%u rto=%u",
1303cf1a6474SDavid Howells 		      __entry->call,
13044700c4d8SDavid Howells 		      __entry->slot,
1305b54a134aSDavid Howells 		      __print_symbolic(__entry->why, rxrpc_rtt_rx_traces),
1306cf1a6474SDavid Howells 		      __entry->send_serial,
1307cf1a6474SDavid Howells 		      __entry->resp_serial,
1308cf1a6474SDavid Howells 		      __entry->rtt,
1309c410bf01SDavid Howells 		      __entry->rto)
1310cf1a6474SDavid Howells 	    );
1311cf1a6474SDavid Howells 
1312fc7ab6d2SDavid Howells TRACE_EVENT(rxrpc_timer,
1313fc7ab6d2SDavid Howells 	    TP_PROTO(struct rxrpc_call *call, enum rxrpc_timer_trace why,
1314a158bdd3SDavid Howells 		     unsigned long now),
1315fc7ab6d2SDavid Howells 
1316a158bdd3SDavid Howells 	    TP_ARGS(call, why, now),
1317fc7ab6d2SDavid Howells 
1318fc7ab6d2SDavid Howells 	    TP_STRUCT__entry(
1319a25e21f0SDavid Howells 		    __field(unsigned int,		call)
1320fc7ab6d2SDavid Howells 		    __field(enum rxrpc_timer_trace,	why)
1321a158bdd3SDavid Howells 		    __field(long,			now)
1322a158bdd3SDavid Howells 		    __field(long,			ack_at)
1323bd1fdf8cSDavid Howells 		    __field(long,			ack_lost_at)
1324a158bdd3SDavid Howells 		    __field(long,			resend_at)
1325a158bdd3SDavid Howells 		    __field(long,			ping_at)
1326a158bdd3SDavid Howells 		    __field(long,			expect_rx_by)
1327a158bdd3SDavid Howells 		    __field(long,			expect_req_by)
1328a158bdd3SDavid Howells 		    __field(long,			expect_term_by)
1329a158bdd3SDavid Howells 		    __field(long,			timer)
1330fc7ab6d2SDavid Howells 			     ),
1331fc7ab6d2SDavid Howells 
1332fc7ab6d2SDavid Howells 	    TP_fast_assign(
1333a25e21f0SDavid Howells 		    __entry->call		= call->debug_id;
1334fc7ab6d2SDavid Howells 		    __entry->why		= why;
1335fc7ab6d2SDavid Howells 		    __entry->now		= now;
1336530403d9SDavid Howells 		    __entry->ack_at		= call->delay_ack_at;
1337bd1fdf8cSDavid Howells 		    __entry->ack_lost_at	= call->ack_lost_at;
1338fc7ab6d2SDavid Howells 		    __entry->resend_at		= call->resend_at;
1339a158bdd3SDavid Howells 		    __entry->expect_rx_by	= call->expect_rx_by;
1340a158bdd3SDavid Howells 		    __entry->expect_req_by	= call->expect_req_by;
1341a158bdd3SDavid Howells 		    __entry->expect_term_by	= call->expect_term_by;
1342fc7ab6d2SDavid Howells 		    __entry->timer		= call->timer.expires;
1343fc7ab6d2SDavid Howells 			   ),
1344fc7ab6d2SDavid Howells 
1345a25e21f0SDavid Howells 	    TP_printk("c=%08x %s a=%ld la=%ld r=%ld xr=%ld xq=%ld xt=%ld t=%ld",
1346fc7ab6d2SDavid Howells 		      __entry->call,
1347b54a134aSDavid Howells 		      __print_symbolic(__entry->why, rxrpc_timer_traces),
1348a158bdd3SDavid Howells 		      __entry->ack_at - __entry->now,
1349bd1fdf8cSDavid Howells 		      __entry->ack_lost_at - __entry->now,
1350a158bdd3SDavid Howells 		      __entry->resend_at - __entry->now,
1351a158bdd3SDavid Howells 		      __entry->expect_rx_by - __entry->now,
1352a158bdd3SDavid Howells 		      __entry->expect_req_by - __entry->now,
1353a158bdd3SDavid Howells 		      __entry->expect_term_by - __entry->now,
1354a158bdd3SDavid Howells 		      __entry->timer - __entry->now)
1355fc7ab6d2SDavid Howells 	    );
1356fc7ab6d2SDavid Howells 
1357334dfbfcSDavid Howells TRACE_EVENT(rxrpc_timer_expired,
1358334dfbfcSDavid Howells 	    TP_PROTO(struct rxrpc_call *call, unsigned long now),
1359334dfbfcSDavid Howells 
1360334dfbfcSDavid Howells 	    TP_ARGS(call, now),
1361334dfbfcSDavid Howells 
1362334dfbfcSDavid Howells 	    TP_STRUCT__entry(
1363334dfbfcSDavid Howells 		    __field(unsigned int,	call)
1364334dfbfcSDavid Howells 		    __field(long,		now)
1365334dfbfcSDavid Howells 		    __field(long,		ack_at)
1366334dfbfcSDavid Howells 		    __field(long,		ack_lost_at)
1367334dfbfcSDavid Howells 		    __field(long,		resend_at)
1368334dfbfcSDavid Howells 		    __field(long,		ping_at)
1369334dfbfcSDavid Howells 		    __field(long,		expect_rx_by)
1370334dfbfcSDavid Howells 		    __field(long,		expect_req_by)
1371334dfbfcSDavid Howells 		    __field(long,		expect_term_by)
1372334dfbfcSDavid Howells 		    __field(long,		timer)
1373334dfbfcSDavid Howells 			     ),
1374334dfbfcSDavid Howells 
1375334dfbfcSDavid Howells 	    TP_fast_assign(
1376334dfbfcSDavid Howells 		    __entry->call		= call->debug_id;
1377334dfbfcSDavid Howells 		    __entry->now		= now;
1378530403d9SDavid Howells 		    __entry->ack_at		= call->delay_ack_at;
1379334dfbfcSDavid Howells 		    __entry->ack_lost_at	= call->ack_lost_at;
1380334dfbfcSDavid Howells 		    __entry->resend_at		= call->resend_at;
1381334dfbfcSDavid Howells 		    __entry->expect_rx_by	= call->expect_rx_by;
1382334dfbfcSDavid Howells 		    __entry->expect_req_by	= call->expect_req_by;
1383334dfbfcSDavid Howells 		    __entry->expect_term_by	= call->expect_term_by;
1384334dfbfcSDavid Howells 		    __entry->timer		= call->timer.expires;
1385334dfbfcSDavid Howells 			   ),
1386334dfbfcSDavid Howells 
1387334dfbfcSDavid Howells 	    TP_printk("c=%08x EXPIRED a=%ld la=%ld r=%ld xr=%ld xq=%ld xt=%ld t=%ld",
1388334dfbfcSDavid Howells 		      __entry->call,
1389334dfbfcSDavid Howells 		      __entry->ack_at - __entry->now,
1390334dfbfcSDavid Howells 		      __entry->ack_lost_at - __entry->now,
1391334dfbfcSDavid Howells 		      __entry->resend_at - __entry->now,
1392334dfbfcSDavid Howells 		      __entry->expect_rx_by - __entry->now,
1393334dfbfcSDavid Howells 		      __entry->expect_req_by - __entry->now,
1394334dfbfcSDavid Howells 		      __entry->expect_term_by - __entry->now,
1395334dfbfcSDavid Howells 		      __entry->timer - __entry->now)
1396334dfbfcSDavid Howells 	    );
1397334dfbfcSDavid Howells 
139889b475abSDavid Howells TRACE_EVENT(rxrpc_rx_lose,
139989b475abSDavid Howells 	    TP_PROTO(struct rxrpc_skb_priv *sp),
140089b475abSDavid Howells 
140189b475abSDavid Howells 	    TP_ARGS(sp),
140289b475abSDavid Howells 
140389b475abSDavid Howells 	    TP_STRUCT__entry(
140489b475abSDavid Howells 		    __field_struct(struct rxrpc_host_header,	hdr)
140589b475abSDavid Howells 			     ),
140689b475abSDavid Howells 
140789b475abSDavid Howells 	    TP_fast_assign(
140889b475abSDavid Howells 		    memcpy(&__entry->hdr, &sp->hdr, sizeof(__entry->hdr));
140989b475abSDavid Howells 			   ),
141089b475abSDavid Howells 
141189b475abSDavid Howells 	    TP_printk("%08x:%08x:%08x:%04x %08x %08x %02x %02x %s *LOSE*",
141289b475abSDavid Howells 		      __entry->hdr.epoch, __entry->hdr.cid,
141389b475abSDavid Howells 		      __entry->hdr.callNumber, __entry->hdr.serviceId,
141489b475abSDavid Howells 		      __entry->hdr.serial, __entry->hdr.seq,
141589b475abSDavid Howells 		      __entry->hdr.type, __entry->hdr.flags,
1416b54a134aSDavid Howells 		      __entry->hdr.type <= 15 ?
1417b54a134aSDavid Howells 		      __print_symbolic(__entry->hdr.type, rxrpc_pkts) : "?UNK")
141889b475abSDavid Howells 	    );
141989b475abSDavid Howells 
14209c7ad434SDavid Howells TRACE_EVENT(rxrpc_propose_ack,
14219c7ad434SDavid Howells 	    TP_PROTO(struct rxrpc_call *call, enum rxrpc_propose_ack_trace why,
1422530403d9SDavid Howells 		     u8 ack_reason, rxrpc_serial_t serial),
14239c7ad434SDavid Howells 
1424530403d9SDavid Howells 	    TP_ARGS(call, why, ack_reason, serial),
14259c7ad434SDavid Howells 
14269c7ad434SDavid Howells 	    TP_STRUCT__entry(
1427a25e21f0SDavid Howells 		    __field(unsigned int,			call)
14289c7ad434SDavid Howells 		    __field(enum rxrpc_propose_ack_trace,	why)
14299c7ad434SDavid Howells 		    __field(rxrpc_serial_t,			serial)
14309c7ad434SDavid Howells 		    __field(u8,					ack_reason)
14319c7ad434SDavid Howells 			     ),
14329c7ad434SDavid Howells 
14339c7ad434SDavid Howells 	    TP_fast_assign(
1434a25e21f0SDavid Howells 		    __entry->call	= call->debug_id;
14359c7ad434SDavid Howells 		    __entry->why	= why;
14369c7ad434SDavid Howells 		    __entry->serial	= serial;
14379c7ad434SDavid Howells 		    __entry->ack_reason	= ack_reason;
14389c7ad434SDavid Howells 			   ),
14399c7ad434SDavid Howells 
1440530403d9SDavid Howells 	    TP_printk("c=%08x %s %s r=%08x",
14419c7ad434SDavid Howells 		      __entry->call,
1442b54a134aSDavid Howells 		      __print_symbolic(__entry->why, rxrpc_propose_ack_traces),
1443b54a134aSDavid Howells 		      __print_symbolic(__entry->ack_reason, rxrpc_ack_names),
1444530403d9SDavid Howells 		      __entry->serial)
14459c7ad434SDavid Howells 	    );
14469c7ad434SDavid Howells 
144772f0c6fbSDavid Howells TRACE_EVENT(rxrpc_send_ack,
144872f0c6fbSDavid Howells 	    TP_PROTO(struct rxrpc_call *call, enum rxrpc_propose_ack_trace why,
144972f0c6fbSDavid Howells 		     u8 ack_reason, rxrpc_serial_t serial),
145072f0c6fbSDavid Howells 
145172f0c6fbSDavid Howells 	    TP_ARGS(call, why, ack_reason, serial),
145272f0c6fbSDavid Howells 
145372f0c6fbSDavid Howells 	    TP_STRUCT__entry(
145472f0c6fbSDavid Howells 		    __field(unsigned int,			call)
145572f0c6fbSDavid Howells 		    __field(enum rxrpc_propose_ack_trace,	why)
145672f0c6fbSDavid Howells 		    __field(rxrpc_serial_t,			serial)
145772f0c6fbSDavid Howells 		    __field(u8,					ack_reason)
145872f0c6fbSDavid Howells 			     ),
145972f0c6fbSDavid Howells 
146072f0c6fbSDavid Howells 	    TP_fast_assign(
146172f0c6fbSDavid Howells 		    __entry->call	= call->debug_id;
146272f0c6fbSDavid Howells 		    __entry->why	= why;
146372f0c6fbSDavid Howells 		    __entry->serial	= serial;
146472f0c6fbSDavid Howells 		    __entry->ack_reason	= ack_reason;
146572f0c6fbSDavid Howells 			   ),
146672f0c6fbSDavid Howells 
146772f0c6fbSDavid Howells 	    TP_printk("c=%08x %s %s r=%08x",
146872f0c6fbSDavid Howells 		      __entry->call,
146972f0c6fbSDavid Howells 		      __print_symbolic(__entry->why, rxrpc_propose_ack_traces),
147072f0c6fbSDavid Howells 		      __print_symbolic(__entry->ack_reason, rxrpc_ack_names),
147172f0c6fbSDavid Howells 		      __entry->serial)
147272f0c6fbSDavid Howells 	    );
147372f0c6fbSDavid Howells 
1474530403d9SDavid Howells TRACE_EVENT(rxrpc_drop_ack,
1475530403d9SDavid Howells 	    TP_PROTO(struct rxrpc_call *call, enum rxrpc_propose_ack_trace why,
1476530403d9SDavid Howells 		     u8 ack_reason, rxrpc_serial_t serial, bool nobuf),
1477530403d9SDavid Howells 
1478530403d9SDavid Howells 	    TP_ARGS(call, why, ack_reason, serial, nobuf),
1479530403d9SDavid Howells 
1480530403d9SDavid Howells 	    TP_STRUCT__entry(
1481530403d9SDavid Howells 		    __field(unsigned int,			call)
1482530403d9SDavid Howells 		    __field(enum rxrpc_propose_ack_trace,	why)
1483530403d9SDavid Howells 		    __field(rxrpc_serial_t,			serial)
1484530403d9SDavid Howells 		    __field(u8,					ack_reason)
1485530403d9SDavid Howells 		    __field(bool,				nobuf)
1486530403d9SDavid Howells 			     ),
1487530403d9SDavid Howells 
1488530403d9SDavid Howells 	    TP_fast_assign(
1489530403d9SDavid Howells 		    __entry->call	= call->debug_id;
1490530403d9SDavid Howells 		    __entry->why	= why;
1491530403d9SDavid Howells 		    __entry->serial	= serial;
1492530403d9SDavid Howells 		    __entry->ack_reason	= ack_reason;
1493530403d9SDavid Howells 		    __entry->nobuf	= nobuf;
1494530403d9SDavid Howells 			   ),
1495530403d9SDavid Howells 
1496530403d9SDavid Howells 	    TP_printk("c=%08x %s %s r=%08x nbf=%u",
1497530403d9SDavid Howells 		      __entry->call,
1498530403d9SDavid Howells 		      __print_symbolic(__entry->why, rxrpc_propose_ack_traces),
1499530403d9SDavid Howells 		      __print_symbolic(__entry->ack_reason, rxrpc_ack_names),
1500530403d9SDavid Howells 		      __entry->serial, __entry->nobuf)
1501530403d9SDavid Howells 	    );
1502530403d9SDavid Howells 
1503c6672e3fSDavid Howells TRACE_EVENT(rxrpc_retransmit,
1504a4ea4c47SDavid Howells 	    TP_PROTO(struct rxrpc_call *call, rxrpc_seq_t seq, s64 expiry),
1505c6672e3fSDavid Howells 
1506a4ea4c47SDavid Howells 	    TP_ARGS(call, seq, expiry),
1507c6672e3fSDavid Howells 
1508c6672e3fSDavid Howells 	    TP_STRUCT__entry(
1509a25e21f0SDavid Howells 		    __field(unsigned int,	call)
1510c6672e3fSDavid Howells 		    __field(rxrpc_seq_t,	seq)
1511c6672e3fSDavid Howells 		    __field(s64,		expiry)
1512c6672e3fSDavid Howells 			     ),
1513c6672e3fSDavid Howells 
1514c6672e3fSDavid Howells 	    TP_fast_assign(
1515a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
1516c6672e3fSDavid Howells 		    __entry->seq = seq;
1517c6672e3fSDavid Howells 		    __entry->expiry = expiry;
1518c6672e3fSDavid Howells 			   ),
1519c6672e3fSDavid Howells 
1520a4ea4c47SDavid Howells 	    TP_printk("c=%08x q=%x xp=%lld",
1521c6672e3fSDavid Howells 		      __entry->call,
1522c6672e3fSDavid Howells 		      __entry->seq,
1523c6672e3fSDavid Howells 		      __entry->expiry)
1524c6672e3fSDavid Howells 	    );
1525c6672e3fSDavid Howells 
152657494343SDavid Howells TRACE_EVENT(rxrpc_congest,
152757494343SDavid Howells 	    TP_PROTO(struct rxrpc_call *call, struct rxrpc_ack_summary *summary,
152857494343SDavid Howells 		     rxrpc_serial_t ack_serial, enum rxrpc_congest_change change),
152957494343SDavid Howells 
153057494343SDavid Howells 	    TP_ARGS(call, summary, ack_serial, change),
153157494343SDavid Howells 
153257494343SDavid Howells 	    TP_STRUCT__entry(
1533a25e21f0SDavid Howells 		    __field(unsigned int,			call)
153457494343SDavid Howells 		    __field(enum rxrpc_congest_change,		change)
153557494343SDavid Howells 		    __field(rxrpc_seq_t,			hard_ack)
153657494343SDavid Howells 		    __field(rxrpc_seq_t,			top)
153757494343SDavid Howells 		    __field(rxrpc_seq_t,			lowest_nak)
153857494343SDavid Howells 		    __field(rxrpc_serial_t,			ack_serial)
153957494343SDavid Howells 		    __field_struct(struct rxrpc_ack_summary,	sum)
154057494343SDavid Howells 			     ),
154157494343SDavid Howells 
154257494343SDavid Howells 	    TP_fast_assign(
1543a25e21f0SDavid Howells 		    __entry->call	= call->debug_id;
154457494343SDavid Howells 		    __entry->change	= change;
1545a4ea4c47SDavid Howells 		    __entry->hard_ack	= call->acks_hard_ack;
154657494343SDavid Howells 		    __entry->top	= call->tx_top;
154757494343SDavid Howells 		    __entry->lowest_nak	= call->acks_lowest_nak;
154857494343SDavid Howells 		    __entry->ack_serial	= ack_serial;
154957494343SDavid Howells 		    memcpy(&__entry->sum, summary, sizeof(__entry->sum));
155057494343SDavid Howells 			   ),
155157494343SDavid Howells 
1552d57a3a15SDavid Howells 	    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",
155357494343SDavid Howells 		      __entry->call,
155457494343SDavid Howells 		      __entry->ack_serial,
1555b54a134aSDavid Howells 		      __print_symbolic(__entry->sum.ack_reason, rxrpc_ack_names),
155657494343SDavid Howells 		      __entry->hard_ack,
1557b54a134aSDavid Howells 		      __print_symbolic(__entry->sum.mode, rxrpc_congest_modes),
155857494343SDavid Howells 		      __entry->sum.cwnd,
155957494343SDavid Howells 		      __entry->sum.ssthresh,
1560d57a3a15SDavid Howells 		      __entry->sum.nr_acks, __entry->sum.saw_nacks,
1561d57a3a15SDavid Howells 		      __entry->sum.nr_new_acks,
156257494343SDavid Howells 		      __entry->sum.nr_rot_new_acks,
156357494343SDavid Howells 		      __entry->top - __entry->hard_ack,
156457494343SDavid Howells 		      __entry->sum.cumulative_acks,
156557494343SDavid Howells 		      __entry->sum.dup_acks,
156657494343SDavid Howells 		      __entry->lowest_nak, __entry->sum.new_low_nack ? "!" : "",
1567b54a134aSDavid Howells 		      __print_symbolic(__entry->change, rxrpc_congest_changes),
156857494343SDavid Howells 		      __entry->sum.retrans_timeo ? " rTxTo" : "")
156957494343SDavid Howells 	    );
157057494343SDavid Howells 
157132cf8edbSDavid Howells TRACE_EVENT(rxrpc_reset_cwnd,
157232cf8edbSDavid Howells 	    TP_PROTO(struct rxrpc_call *call, ktime_t now),
157332cf8edbSDavid Howells 
157432cf8edbSDavid Howells 	    TP_ARGS(call, now),
157532cf8edbSDavid Howells 
157632cf8edbSDavid Howells 	    TP_STRUCT__entry(
157732cf8edbSDavid Howells 		    __field(unsigned int,		call)
157832cf8edbSDavid Howells 		    __field(enum rxrpc_congest_mode,	mode)
157932cf8edbSDavid Howells 		    __field(unsigned short,		cwnd)
158032cf8edbSDavid Howells 		    __field(unsigned short,		extra)
158132cf8edbSDavid Howells 		    __field(rxrpc_seq_t,		hard_ack)
158232cf8edbSDavid Howells 		    __field(rxrpc_seq_t,		prepared)
158332cf8edbSDavid Howells 		    __field(ktime_t,			since_last_tx)
158432cf8edbSDavid Howells 		    __field(bool,			has_data)
158532cf8edbSDavid Howells 			     ),
158632cf8edbSDavid Howells 
158732cf8edbSDavid Howells 	    TP_fast_assign(
158832cf8edbSDavid Howells 		    __entry->call	= call->debug_id;
158932cf8edbSDavid Howells 		    __entry->mode	= call->cong_mode;
159032cf8edbSDavid Howells 		    __entry->cwnd	= call->cong_cwnd;
159132cf8edbSDavid Howells 		    __entry->extra	= call->cong_extra;
159232cf8edbSDavid Howells 		    __entry->hard_ack	= call->acks_hard_ack;
159332cf8edbSDavid Howells 		    __entry->prepared	= call->tx_prepared - call->tx_bottom;
159432cf8edbSDavid Howells 		    __entry->since_last_tx = ktime_sub(now, call->tx_last_sent);
159532cf8edbSDavid Howells 		    __entry->has_data	= !list_empty(&call->tx_sendmsg);
159632cf8edbSDavid Howells 			   ),
159732cf8edbSDavid Howells 
159832cf8edbSDavid Howells 	    TP_printk("c=%08x q=%08x %s cw=%u+%u pr=%u tm=%llu d=%u",
159932cf8edbSDavid Howells 		      __entry->call,
160032cf8edbSDavid Howells 		      __entry->hard_ack,
160132cf8edbSDavid Howells 		      __print_symbolic(__entry->mode, rxrpc_congest_modes),
160232cf8edbSDavid Howells 		      __entry->cwnd,
160332cf8edbSDavid Howells 		      __entry->extra,
160432cf8edbSDavid Howells 		      __entry->prepared,
160532cf8edbSDavid Howells 		      ktime_to_ns(__entry->since_last_tx),
160632cf8edbSDavid Howells 		      __entry->has_data)
160732cf8edbSDavid Howells 	    );
160832cf8edbSDavid Howells 
1609b1d9f7fdSDavid Howells TRACE_EVENT(rxrpc_disconnect_call,
1610b1d9f7fdSDavid Howells 	    TP_PROTO(struct rxrpc_call *call),
1611b1d9f7fdSDavid Howells 
1612b1d9f7fdSDavid Howells 	    TP_ARGS(call),
1613b1d9f7fdSDavid Howells 
1614b1d9f7fdSDavid Howells 	    TP_STRUCT__entry(
1615a25e21f0SDavid Howells 		    __field(unsigned int,	call)
1616b1d9f7fdSDavid Howells 		    __field(u32,		abort_code)
1617b1d9f7fdSDavid Howells 			     ),
1618b1d9f7fdSDavid Howells 
1619b1d9f7fdSDavid Howells 	    TP_fast_assign(
1620a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
1621b1d9f7fdSDavid Howells 		    __entry->abort_code = call->abort_code;
1622b1d9f7fdSDavid Howells 			   ),
1623b1d9f7fdSDavid Howells 
1624a25e21f0SDavid Howells 	    TP_printk("c=%08x ab=%08x",
1625b1d9f7fdSDavid Howells 		      __entry->call,
1626b1d9f7fdSDavid Howells 		      __entry->abort_code)
1627b1d9f7fdSDavid Howells 	    );
1628b1d9f7fdSDavid Howells 
1629b1d9f7fdSDavid Howells TRACE_EVENT(rxrpc_improper_term,
1630b1d9f7fdSDavid Howells 	    TP_PROTO(struct rxrpc_call *call),
1631b1d9f7fdSDavid Howells 
1632b1d9f7fdSDavid Howells 	    TP_ARGS(call),
1633b1d9f7fdSDavid Howells 
1634b1d9f7fdSDavid Howells 	    TP_STRUCT__entry(
1635a25e21f0SDavid Howells 		    __field(unsigned int,	call)
1636b1d9f7fdSDavid Howells 		    __field(u32,		abort_code)
1637b1d9f7fdSDavid Howells 			     ),
1638b1d9f7fdSDavid Howells 
1639b1d9f7fdSDavid Howells 	    TP_fast_assign(
1640a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
1641b1d9f7fdSDavid Howells 		    __entry->abort_code = call->abort_code;
1642b1d9f7fdSDavid Howells 			   ),
1643b1d9f7fdSDavid Howells 
1644a25e21f0SDavid Howells 	    TP_printk("c=%08x ab=%08x",
1645b1d9f7fdSDavid Howells 		      __entry->call,
1646b1d9f7fdSDavid Howells 		      __entry->abort_code)
1647b1d9f7fdSDavid Howells 	    );
1648b1d9f7fdSDavid Howells 
164989ca6948SDavid Howells TRACE_EVENT(rxrpc_connect_call,
165089ca6948SDavid Howells 	    TP_PROTO(struct rxrpc_call *call),
165189ca6948SDavid Howells 
165289ca6948SDavid Howells 	    TP_ARGS(call),
165389ca6948SDavid Howells 
165489ca6948SDavid Howells 	    TP_STRUCT__entry(
1655a25e21f0SDavid Howells 		    __field(unsigned int,		call)
165689ca6948SDavid Howells 		    __field(unsigned long,		user_call_ID)
165789ca6948SDavid Howells 		    __field(u32,			cid)
165889ca6948SDavid Howells 		    __field(u32,			call_id)
16595e6ef4f1SDavid Howells 		    __field_struct(struct sockaddr_rxrpc, srx)
166089ca6948SDavid Howells 			     ),
166189ca6948SDavid Howells 
166289ca6948SDavid Howells 	    TP_fast_assign(
1663a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
166489ca6948SDavid Howells 		    __entry->user_call_ID = call->user_call_ID;
166589ca6948SDavid Howells 		    __entry->cid = call->cid;
166689ca6948SDavid Howells 		    __entry->call_id = call->call_id;
16675e6ef4f1SDavid Howells 		    __entry->srx = call->dest_srx;
166889ca6948SDavid Howells 			   ),
166989ca6948SDavid Howells 
16705e6ef4f1SDavid Howells 	    TP_printk("c=%08x u=%p %08x:%08x dst=%pISp",
167189ca6948SDavid Howells 		      __entry->call,
167289ca6948SDavid Howells 		      (void *)__entry->user_call_ID,
167389ca6948SDavid Howells 		      __entry->cid,
16745e6ef4f1SDavid Howells 		      __entry->call_id,
16755e6ef4f1SDavid Howells 		      &__entry->srx.transport)
167689ca6948SDavid Howells 	    );
167789ca6948SDavid Howells 
1678827efed6SDavid Howells TRACE_EVENT(rxrpc_resend,
16795e6ef4f1SDavid Howells 	    TP_PROTO(struct rxrpc_call *call, struct sk_buff *ack),
1680827efed6SDavid Howells 
16815e6ef4f1SDavid Howells 	    TP_ARGS(call, ack),
1682827efed6SDavid Howells 
1683827efed6SDavid Howells 	    TP_STRUCT__entry(
1684a25e21f0SDavid Howells 		    __field(unsigned int,	call)
1685a4ea4c47SDavid Howells 		    __field(rxrpc_seq_t,	seq)
16865e6ef4f1SDavid Howells 		    __field(rxrpc_seq_t,	transmitted)
16875e6ef4f1SDavid Howells 		    __field(rxrpc_serial_t,	ack_serial)
1688827efed6SDavid Howells 			     ),
1689827efed6SDavid Howells 
1690827efed6SDavid Howells 	    TP_fast_assign(
16915e6ef4f1SDavid Howells 		    struct rxrpc_skb_priv *sp = ack ? rxrpc_skb(ack) : NULL;
1692a25e21f0SDavid Howells 		    __entry->call = call->debug_id;
1693a4ea4c47SDavid Howells 		    __entry->seq = call->acks_hard_ack;
16945e6ef4f1SDavid Howells 		    __entry->transmitted = call->tx_transmitted;
16955e6ef4f1SDavid Howells 		    __entry->ack_serial = sp ? sp->hdr.serial : 0;
1696827efed6SDavid Howells 			   ),
1697827efed6SDavid Howells 
16985e6ef4f1SDavid Howells 	    TP_printk("c=%08x r=%x q=%x tq=%x",
1699827efed6SDavid Howells 		      __entry->call,
17005e6ef4f1SDavid Howells 		      __entry->ack_serial,
17015e6ef4f1SDavid Howells 		      __entry->seq,
17025e6ef4f1SDavid Howells 		      __entry->transmitted)
1703827efed6SDavid Howells 	    );
1704827efed6SDavid Howells 
1705494337c9SDavid Howells TRACE_EVENT(rxrpc_rx_icmp,
1706494337c9SDavid Howells 	    TP_PROTO(struct rxrpc_peer *peer, struct sock_extended_err *ee,
1707494337c9SDavid Howells 		     struct sockaddr_rxrpc *srx),
1708494337c9SDavid Howells 
1709494337c9SDavid Howells 	    TP_ARGS(peer, ee, srx),
1710494337c9SDavid Howells 
1711494337c9SDavid Howells 	    TP_STRUCT__entry(
1712494337c9SDavid Howells 		    __field(unsigned int,			peer)
1713494337c9SDavid Howells 		    __field_struct(struct sock_extended_err,	ee)
1714494337c9SDavid Howells 		    __field_struct(struct sockaddr_rxrpc,	srx)
1715494337c9SDavid Howells 			     ),
1716494337c9SDavid Howells 
1717494337c9SDavid Howells 	    TP_fast_assign(
1718494337c9SDavid Howells 		    __entry->peer = peer->debug_id;
1719494337c9SDavid Howells 		    memcpy(&__entry->ee, ee, sizeof(__entry->ee));
1720494337c9SDavid Howells 		    memcpy(&__entry->srx, srx, sizeof(__entry->srx));
1721494337c9SDavid Howells 			   ),
1722494337c9SDavid Howells 
1723494337c9SDavid Howells 	    TP_printk("P=%08x o=%u t=%u c=%u i=%u d=%u e=%d %pISp",
1724494337c9SDavid Howells 		      __entry->peer,
1725494337c9SDavid Howells 		      __entry->ee.ee_origin,
1726494337c9SDavid Howells 		      __entry->ee.ee_type,
1727494337c9SDavid Howells 		      __entry->ee.ee_code,
1728494337c9SDavid Howells 		      __entry->ee.ee_info,
1729494337c9SDavid Howells 		      __entry->ee.ee_data,
1730494337c9SDavid Howells 		      __entry->ee.ee_errno,
1731494337c9SDavid Howells 		      &__entry->srx.transport)
1732494337c9SDavid Howells 	    );
1733494337c9SDavid Howells 
17346b47fe1dSDavid Howells TRACE_EVENT(rxrpc_tx_fail,
17356b47fe1dSDavid Howells 	    TP_PROTO(unsigned int debug_id, rxrpc_serial_t serial, int ret,
17364764c0daSDavid Howells 		     enum rxrpc_tx_point where),
17376b47fe1dSDavid Howells 
17384764c0daSDavid Howells 	    TP_ARGS(debug_id, serial, ret, where),
17396b47fe1dSDavid Howells 
17406b47fe1dSDavid Howells 	    TP_STRUCT__entry(
17416b47fe1dSDavid Howells 		    __field(unsigned int,		debug_id)
17426b47fe1dSDavid Howells 		    __field(rxrpc_serial_t,		serial)
17436b47fe1dSDavid Howells 		    __field(int,			ret)
17444764c0daSDavid Howells 		    __field(enum rxrpc_tx_point,	where)
17456b47fe1dSDavid Howells 			     ),
17466b47fe1dSDavid Howells 
17476b47fe1dSDavid Howells 	    TP_fast_assign(
17486b47fe1dSDavid Howells 		    __entry->debug_id = debug_id;
17496b47fe1dSDavid Howells 		    __entry->serial = serial;
17506b47fe1dSDavid Howells 		    __entry->ret = ret;
17514764c0daSDavid Howells 		    __entry->where = where;
17526b47fe1dSDavid Howells 			   ),
17536b47fe1dSDavid Howells 
17546b47fe1dSDavid Howells 	    TP_printk("c=%08x r=%x ret=%d %s",
17556b47fe1dSDavid Howells 		      __entry->debug_id,
17566b47fe1dSDavid Howells 		      __entry->serial,
17576b47fe1dSDavid Howells 		      __entry->ret,
17584764c0daSDavid Howells 		      __print_symbolic(__entry->where, rxrpc_tx_points))
17596b47fe1dSDavid Howells 	    );
17606b47fe1dSDavid Howells 
17611a025028SDavid Howells TRACE_EVENT(rxrpc_call_reset,
17621a025028SDavid Howells 	    TP_PROTO(struct rxrpc_call *call),
17631a025028SDavid Howells 
17641a025028SDavid Howells 	    TP_ARGS(call),
17651a025028SDavid Howells 
17661a025028SDavid Howells 	    TP_STRUCT__entry(
17671a025028SDavid Howells 		    __field(unsigned int,	debug_id)
17681a025028SDavid Howells 		    __field(u32,		cid)
17691a025028SDavid Howells 		    __field(u32,		call_id)
17701a025028SDavid Howells 		    __field(rxrpc_serial_t,	call_serial)
17711a025028SDavid Howells 		    __field(rxrpc_serial_t,	conn_serial)
17721a025028SDavid Howells 		    __field(rxrpc_seq_t,	tx_seq)
17731a025028SDavid Howells 		    __field(rxrpc_seq_t,	rx_seq)
17741a025028SDavid Howells 			     ),
17751a025028SDavid Howells 
17761a025028SDavid Howells 	    TP_fast_assign(
17771a025028SDavid Howells 		    __entry->debug_id = call->debug_id;
17781a025028SDavid Howells 		    __entry->cid = call->cid;
17791a025028SDavid Howells 		    __entry->call_id = call->call_id;
17801a025028SDavid Howells 		    __entry->call_serial = call->rx_serial;
17811a025028SDavid Howells 		    __entry->conn_serial = call->conn->hi_serial;
1782a4ea4c47SDavid Howells 		    __entry->tx_seq = call->acks_hard_ack;
17835d7edbc9SDavid Howells 		    __entry->rx_seq = call->rx_highest_seq;
17841a025028SDavid Howells 			   ),
17851a025028SDavid Howells 
17861a025028SDavid Howells 	    TP_printk("c=%08x %08x:%08x r=%08x/%08x tx=%08x rx=%08x",
17871a025028SDavid Howells 		      __entry->debug_id,
17881a025028SDavid Howells 		      __entry->cid, __entry->call_id,
17891a025028SDavid Howells 		      __entry->call_serial, __entry->conn_serial,
17901a025028SDavid Howells 		      __entry->tx_seq, __entry->rx_seq)
17911a025028SDavid Howells 	    );
17921a025028SDavid Howells 
17934272d303SDavid Howells TRACE_EVENT(rxrpc_notify_socket,
17944272d303SDavid Howells 	    TP_PROTO(unsigned int debug_id, rxrpc_serial_t serial),
17954272d303SDavid Howells 
17964272d303SDavid Howells 	    TP_ARGS(debug_id, serial),
17974272d303SDavid Howells 
17984272d303SDavid Howells 	    TP_STRUCT__entry(
17994272d303SDavid Howells 		    __field(unsigned int,	debug_id)
18004272d303SDavid Howells 		    __field(rxrpc_serial_t,	serial)
18014272d303SDavid Howells 			     ),
18024272d303SDavid Howells 
18034272d303SDavid Howells 	    TP_fast_assign(
18044272d303SDavid Howells 		    __entry->debug_id = debug_id;
18054272d303SDavid Howells 		    __entry->serial = serial;
18064272d303SDavid Howells 			   ),
18074272d303SDavid Howells 
18084272d303SDavid Howells 	    TP_printk("c=%08x r=%08x",
18094272d303SDavid Howells 		      __entry->debug_id,
18104272d303SDavid Howells 		      __entry->serial)
18114272d303SDavid Howells 	    );
18124272d303SDavid Howells 
1813d1f12947SDavid Howells TRACE_EVENT(rxrpc_rx_discard_ack,
1814d1f12947SDavid Howells 	    TP_PROTO(unsigned int debug_id, rxrpc_serial_t serial,
1815d1f12947SDavid Howells 		     rxrpc_seq_t first_soft_ack, rxrpc_seq_t call_ackr_first,
1816d1f12947SDavid Howells 		     rxrpc_seq_t prev_pkt, rxrpc_seq_t call_ackr_prev),
1817d1f12947SDavid Howells 
1818d1f12947SDavid Howells 	    TP_ARGS(debug_id, serial, first_soft_ack, call_ackr_first,
1819d1f12947SDavid Howells 		    prev_pkt, call_ackr_prev),
1820d1f12947SDavid Howells 
1821d1f12947SDavid Howells 	    TP_STRUCT__entry(
1822d1f12947SDavid Howells 		    __field(unsigned int,	debug_id)
1823d1f12947SDavid Howells 		    __field(rxrpc_serial_t,	serial)
1824d1f12947SDavid Howells 		    __field(rxrpc_seq_t,	first_soft_ack)
1825d1f12947SDavid Howells 		    __field(rxrpc_seq_t,	call_ackr_first)
1826d1f12947SDavid Howells 		    __field(rxrpc_seq_t,	prev_pkt)
1827d1f12947SDavid Howells 		    __field(rxrpc_seq_t,	call_ackr_prev)
1828d1f12947SDavid Howells 			     ),
1829d1f12947SDavid Howells 
1830d1f12947SDavid Howells 	    TP_fast_assign(
1831d1f12947SDavid Howells 		    __entry->debug_id		= debug_id;
1832d1f12947SDavid Howells 		    __entry->serial		= serial;
1833d1f12947SDavid Howells 		    __entry->first_soft_ack	= first_soft_ack;
1834d1f12947SDavid Howells 		    __entry->call_ackr_first	= call_ackr_first;
1835d1f12947SDavid Howells 		    __entry->prev_pkt		= prev_pkt;
1836d1f12947SDavid Howells 		    __entry->call_ackr_prev	= call_ackr_prev;
1837d1f12947SDavid Howells 			   ),
1838d1f12947SDavid Howells 
1839d1f12947SDavid Howells 	    TP_printk("c=%08x r=%08x %08x<%08x %08x<%08x",
1840d1f12947SDavid Howells 		      __entry->debug_id,
1841d1f12947SDavid Howells 		      __entry->serial,
1842d1f12947SDavid Howells 		      __entry->first_soft_ack,
1843d1f12947SDavid Howells 		      __entry->call_ackr_first,
1844d1f12947SDavid Howells 		      __entry->prev_pkt,
1845d1f12947SDavid Howells 		      __entry->call_ackr_prev)
1846d1f12947SDavid Howells 	    );
1847d1f12947SDavid Howells 
18484d843be5SDavid Howells TRACE_EVENT(rxrpc_req_ack,
18494d843be5SDavid Howells 	    TP_PROTO(unsigned int call_debug_id, rxrpc_seq_t seq,
18504d843be5SDavid Howells 		     enum rxrpc_req_ack_trace why),
18514d843be5SDavid Howells 
18524d843be5SDavid Howells 	    TP_ARGS(call_debug_id, seq, why),
18534d843be5SDavid Howells 
18544d843be5SDavid Howells 	    TP_STRUCT__entry(
18554d843be5SDavid Howells 		    __field(unsigned int,		call_debug_id)
18564d843be5SDavid Howells 		    __field(rxrpc_seq_t,		seq)
18574d843be5SDavid Howells 		    __field(enum rxrpc_req_ack_trace,	why)
18584d843be5SDavid Howells 			     ),
18594d843be5SDavid Howells 
18604d843be5SDavid Howells 	    TP_fast_assign(
18614d843be5SDavid Howells 		    __entry->call_debug_id = call_debug_id;
18624d843be5SDavid Howells 		    __entry->seq = seq;
18634d843be5SDavid Howells 		    __entry->why = why;
18644d843be5SDavid Howells 			   ),
18654d843be5SDavid Howells 
18664d843be5SDavid Howells 	    TP_printk("c=%08x q=%08x REQ-%s",
18674d843be5SDavid Howells 		      __entry->call_debug_id,
18684d843be5SDavid Howells 		      __entry->seq,
18694d843be5SDavid Howells 		      __print_symbolic(__entry->why, rxrpc_req_ack_traces))
18704d843be5SDavid Howells 	    );
18714d843be5SDavid Howells 
187202a19356SDavid Howells TRACE_EVENT(rxrpc_txbuf,
187302a19356SDavid Howells 	    TP_PROTO(unsigned int debug_id,
187402a19356SDavid Howells 		     unsigned int call_debug_id, rxrpc_seq_t seq,
187502a19356SDavid Howells 		     int ref, enum rxrpc_txbuf_trace what),
187602a19356SDavid Howells 
187702a19356SDavid Howells 	    TP_ARGS(debug_id, call_debug_id, seq, ref, what),
187802a19356SDavid Howells 
187902a19356SDavid Howells 	    TP_STRUCT__entry(
188002a19356SDavid Howells 		    __field(unsigned int,		debug_id)
188102a19356SDavid Howells 		    __field(unsigned int,		call_debug_id)
188202a19356SDavid Howells 		    __field(rxrpc_seq_t,		seq)
188302a19356SDavid Howells 		    __field(int,			ref)
188402a19356SDavid Howells 		    __field(enum rxrpc_txbuf_trace,	what)
188502a19356SDavid Howells 			     ),
188602a19356SDavid Howells 
188702a19356SDavid Howells 	    TP_fast_assign(
188802a19356SDavid Howells 		    __entry->debug_id = debug_id;
188902a19356SDavid Howells 		    __entry->call_debug_id = call_debug_id;
189002a19356SDavid Howells 		    __entry->seq = seq;
189102a19356SDavid Howells 		    __entry->ref = ref;
189202a19356SDavid Howells 		    __entry->what = what;
189302a19356SDavid Howells 			   ),
189402a19356SDavid Howells 
189502a19356SDavid Howells 	    TP_printk("B=%08x c=%08x q=%08x %s r=%d",
189602a19356SDavid Howells 		      __entry->debug_id,
189702a19356SDavid Howells 		      __entry->call_debug_id,
189802a19356SDavid Howells 		      __entry->seq,
189902a19356SDavid Howells 		      __print_symbolic(__entry->what, rxrpc_txbuf_traces),
190002a19356SDavid Howells 		      __entry->ref)
190102a19356SDavid Howells 	    );
190202a19356SDavid Howells 
190315f661dcSDavid Howells TRACE_EVENT(rxrpc_poke_call,
190415f661dcSDavid Howells 	    TP_PROTO(struct rxrpc_call *call, bool busy,
190515f661dcSDavid Howells 		     enum rxrpc_call_poke_trace what),
190615f661dcSDavid Howells 
190715f661dcSDavid Howells 	    TP_ARGS(call, busy, what),
190815f661dcSDavid Howells 
190915f661dcSDavid Howells 	    TP_STRUCT__entry(
191015f661dcSDavid Howells 		    __field(unsigned int,		call_debug_id)
191115f661dcSDavid Howells 		    __field(bool,			busy)
191215f661dcSDavid Howells 		    __field(enum rxrpc_call_poke_trace,	what)
191315f661dcSDavid Howells 			     ),
191415f661dcSDavid Howells 
191515f661dcSDavid Howells 	    TP_fast_assign(
191615f661dcSDavid Howells 		    __entry->call_debug_id = call->debug_id;
191715f661dcSDavid Howells 		    __entry->busy = busy;
191815f661dcSDavid Howells 		    __entry->what = what;
191915f661dcSDavid Howells 			   ),
192015f661dcSDavid Howells 
192115f661dcSDavid Howells 	    TP_printk("c=%08x %s%s",
192215f661dcSDavid Howells 		      __entry->call_debug_id,
192315f661dcSDavid Howells 		      __print_symbolic(__entry->what, rxrpc_call_poke_traces),
192415f661dcSDavid Howells 		      __entry->busy ? "!" : "")
192515f661dcSDavid Howells 	    );
192615f661dcSDavid Howells 
192715f661dcSDavid Howells TRACE_EVENT(rxrpc_call_poked,
192815f661dcSDavid Howells 	    TP_PROTO(struct rxrpc_call *call),
192915f661dcSDavid Howells 
193015f661dcSDavid Howells 	    TP_ARGS(call),
193115f661dcSDavid Howells 
193215f661dcSDavid Howells 	    TP_STRUCT__entry(
193315f661dcSDavid Howells 		    __field(unsigned int,	call_debug_id)
193415f661dcSDavid Howells 			     ),
193515f661dcSDavid Howells 
193615f661dcSDavid Howells 	    TP_fast_assign(
193715f661dcSDavid Howells 		    __entry->call_debug_id = call->debug_id;
193815f661dcSDavid Howells 			   ),
193915f661dcSDavid Howells 
194015f661dcSDavid Howells 	    TP_printk("c=%08x",
194115f661dcSDavid Howells 		      __entry->call_debug_id)
194215f661dcSDavid Howells 	    );
194315f661dcSDavid Howells 
1944f21e9348SDavid Howells TRACE_EVENT(rxrpc_sack,
1945f21e9348SDavid Howells 	    TP_PROTO(struct rxrpc_call *call, rxrpc_seq_t seq,
1946f21e9348SDavid Howells 		     unsigned int sack, enum rxrpc_sack_trace what),
1947f21e9348SDavid Howells 
1948f21e9348SDavid Howells 	    TP_ARGS(call, seq, sack, what),
1949f21e9348SDavid Howells 
1950f21e9348SDavid Howells 	    TP_STRUCT__entry(
1951f21e9348SDavid Howells 		    __field(unsigned int,		call_debug_id)
1952f21e9348SDavid Howells 		    __field(rxrpc_seq_t,		seq)
1953f21e9348SDavid Howells 		    __field(unsigned int,		sack)
1954f21e9348SDavid Howells 		    __field(enum rxrpc_sack_trace,	what)
1955f21e9348SDavid Howells 			     ),
1956f21e9348SDavid Howells 
1957f21e9348SDavid Howells 	    TP_fast_assign(
1958f21e9348SDavid Howells 		    __entry->call_debug_id = call->debug_id;
1959f21e9348SDavid Howells 		    __entry->seq = seq;
1960f21e9348SDavid Howells 		    __entry->sack = sack;
1961f21e9348SDavid Howells 		    __entry->what = what;
1962f21e9348SDavid Howells 			   ),
1963f21e9348SDavid Howells 
1964f21e9348SDavid Howells 	    TP_printk("c=%08x q=%08x %s k=%x",
1965f21e9348SDavid Howells 		      __entry->call_debug_id,
1966f21e9348SDavid Howells 		      __entry->seq,
1967f21e9348SDavid Howells 		      __print_symbolic(__entry->what, rxrpc_sack_traces),
1968f21e9348SDavid Howells 		      __entry->sack)
1969f21e9348SDavid Howells 	    );
1970f21e9348SDavid Howells 
1971dc9fd093SDavid Howells #undef EM
1972dc9fd093SDavid Howells #undef E_
197357af281eSDavid Howells 
197457af281eSDavid Howells #endif /* RXRPC_TRACE_ONLY_DEFINE_ENUMS */
1975df844fd4SDavid Howells #endif /* _TRACE_RXRPC_H */
1976df844fd4SDavid Howells 
1977df844fd4SDavid Howells /* This part must be outside protection */
1978df844fd4SDavid Howells #include <trace/define_trace.h>
1979