linux-trace-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] net/tcp_ao: tracing: Hide tcp_ao events under CONFIG_TCP_AO
@ 2025-06-12 13:46 Steven Rostedt
  2025-06-14 15:30 ` Simon Horman
  2025-06-16 22:10 ` patchwork-bot+netdevbpf
  0 siblings, 2 replies; 6+ messages in thread
From: Steven Rostedt @ 2025-06-12 13:46 UTC (permalink / raw)
  To: LKML, Linux trace kernel, netdev
  Cc: Masami Hiramatsu, Mathieu Desnoyers, Eric Dumazet, Neal Cardwell,
	Kuniyuki Iwashima

From: Steven Rostedt <rostedt@goodmis.org>

Several of the tcp_ao events are only called when CONFIG_TCP_AO is
defined. As each event can take up to 5K regardless if they are used or
not, it's best not to define them when they are not used. Add #ifdef
around these events when they are not used.

Signed-off-by: Steven Rostedt (Google) <rostedt@goodmis.org>
---
Note, I will be adding code soon that will make unused event cause a warning.

 include/trace/events/tcp.h | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/include/trace/events/tcp.h b/include/trace/events/tcp.h
index 95f59c1a6f57..54e60c6009e3 100644
--- a/include/trace/events/tcp.h
+++ b/include/trace/events/tcp.h
@@ -692,6 +692,7 @@ DEFINE_EVENT(tcp_ao_event, tcp_ao_handshake_failure,
 	TP_ARGS(sk, skb, keyid, rnext, maclen)
 );
 
+#ifdef CONFIG_TCP_AO
 DEFINE_EVENT(tcp_ao_event, tcp_ao_wrong_maclen,
 	TP_PROTO(const struct sock *sk, const struct sk_buff *skb,
 		 const __u8 keyid, const __u8 rnext, const __u8 maclen),
@@ -830,6 +831,7 @@ DEFINE_EVENT(tcp_ao_event_sne, tcp_ao_rcv_sne_update,
 	TP_PROTO(const struct sock *sk, __u32 new_sne),
 	TP_ARGS(sk, new_sne)
 );
+#endif /* CONFIG_TCP_AO */
 
 #endif /* _TRACE_TCP_H */
 
-- 
2.47.2


^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2025-06-16 22:10 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-06-12 13:46 [PATCH] net/tcp_ao: tracing: Hide tcp_ao events under CONFIG_TCP_AO Steven Rostedt
2025-06-14 15:30 ` Simon Horman
2025-06-16 18:47   ` Steven Rostedt
2025-06-16 20:18     ` Jakub Kicinski
2025-06-16 20:20       ` Steven Rostedt
2025-06-16 22:10 ` patchwork-bot+netdevbpf

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).