summaryrefslogtreecommitdiff
path: root/tools/testing/selftests/bpf/prog_tests/tcp_rtt.c
diff options
context:
space:
mode:
authorTony Ambardar <tony.ambardar@gmail.com>2024-07-22 22:54:40 -0700
committerAndrii Nakryiko <andrii@kernel.org>2024-07-29 15:05:08 -0700
commit5e4c43bcb85973243d7274e0058b6e8f5810e4f7 (patch)
tree1031b480e674b7cbee7aa070b031ef0562d6782e /tools/testing/selftests/bpf/prog_tests/tcp_rtt.c
parentbae9a5ce7d3a9b3a9e07b31ab9e9c58450e3e9fd (diff)
selftests/bpf: Fix compiling flow_dissector.c with musl-libc
The GNU version of 'struct tcphdr' has members 'doff', 'source' and 'dest', which are not exposed by musl libc headers unless _GNU_SOURCE is defined. Add this definition to fix errors seen compiling for mips64el/musl-libc: flow_dissector.c:118:30: error: 'struct tcphdr' has no member named 'doff' 118 | .tcp.doff = 5, | ^~~~ flow_dissector.c:119:30: error: 'struct tcphdr' has no member named 'source' 119 | .tcp.source = 80, | ^~~~~~ flow_dissector.c:120:30: error: 'struct tcphdr' has no member named 'dest' 120 | .tcp.dest = 8080, | ^~~~ Fixes: ae173a915785 ("selftests/bpf: support BPF_FLOW_DISSECTOR_F_PARSE_1ST_FRAG") Signed-off-by: Tony Ambardar <tony.ambardar@gmail.com> Signed-off-by: Andrii Nakryiko <andrii@kernel.org> Link: https://lore.kernel.org/bpf/8f7ab21a73f678f9cebd32b26c444a686e57414d.1721713597.git.tony.ambardar@gmail.com
Diffstat (limited to 'tools/testing/selftests/bpf/prog_tests/tcp_rtt.c')
0 files changed, 0 insertions, 0 deletions