aboutsummaryrefslogtreecommitdiff
path: root/lib/test-string_helpers.c
diff options
context:
space:
mode:
authorCong Wang <[email protected]>2017-10-13 13:03:16 -0700
committerDavid S. Miller <[email protected]>2017-10-14 18:45:15 -0700
commite086101b150ae8e99e54ab26101ef3835fa9f48d (patch)
tree5eb147e546eac44c5dd83b7e5dd1c6263c7678eb /lib/test-string_helpers.c
parent657875944726af8f881df7d431afbbe8f50ad4d7 (diff)
tcp: add a tracepoint for tcp retransmission
We need a real-time notification for tcp retransmission for monitoring. Of course we could use ftrace to dynamically instrument this kernel function too, however we can't retrieve the connection information at the same time, for example perf-tools [1] reads /proc/net/tcp for socket details, which is slow when we have a lots of connections. Therefore, this patch adds a tracepoint for __tcp_retransmit_skb() and exposes src/dst IP addresses and ports of the connection. This also makes it easier to integrate into perf. Note, I expose both IPv4 and IPv6 addresses at the same time: for a IPv4 socket, v4 mapped address is used as IPv6 addresses, for a IPv6 socket, LOOPBACK4_IPV6 is already filled by kernel. Also, add sk and skb pointers as they are useful for BPF. 1. https://github.com/brendangregg/perf-tools/blob/master/net/tcpretrans Cc: Eric Dumazet <[email protected]> Cc: Alexei Starovoitov <[email protected]> Cc: Hannes Frederic Sowa <[email protected]> Cc: Brendan Gregg <[email protected]> Cc: Neal Cardwell <[email protected]> Signed-off-by: Cong Wang <[email protected]> Acked-by: Alexei Starovoitov <[email protected]> Acked-by: Brendan Gregg <[email protected]> Signed-off-by: David S. Miller <[email protected]>
Diffstat (limited to 'lib/test-string_helpers.c')
0 files changed, 0 insertions, 0 deletions