linux/tools/testing/selftests/bpf/prog_tests
John Fastabend f2e97dc126 bpf: Selftests build error in sockmap_basic.c
Fix following build error. We could push a tcp.h header into one of the
include paths, but I think its easy enough to simply pull in the three
defines we need here. If we end up using more of tcp.h at some point
we can pull it in later.

/home/john/git/bpf/tools/testing/selftests/bpf/prog_tests/sockmap_basic.c: In function ‘connected_socket_v4’:
/home/john/git/bpf/tools/testing/selftests/bpf/prog_tests/sockmap_basic.c:20:11: error: ‘TCP_REPAIR_ON’ undeclared (first use in this function)
  repair = TCP_REPAIR_ON;
           ^
/home/john/git/bpf/tools/testing/selftests/bpf/prog_tests/sockmap_basic.c:20:11: note: each undeclared identifier is reported only once for each function it appears in
/home/john/git/bpf/tools/testing/selftests/bpf/prog_tests/sockmap_basic.c:29:11: error: ‘TCP_REPAIR_OFF_NO_WP’ undeclared (first use in this function)
  repair = TCP_REPAIR_OFF_NO_WP;

Then with fix,

$ ./test_progs -n 44
#44/1 sockmap create_update_free:OK
#44/2 sockhash create_update_free:OK
#44 sockmap_basic:OK

Fixes: 5d3919a953 ("selftests/bpf: Test freeing sockmap/sockhash with a socket in it")
Signed-off-by: John Fastabend <john.fastabend@gmail.com>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Reviewed-by: Jakub Sitnicki <jakub@cloudflare.com>
Link: https://lore.kernel.org/bpf/158131347731.21414.12120493483848386652.stgit@john-Precision-5820-Tower
2020-02-10 14:31:34 -08:00
..
.gitignore
attach_probe.c selftests/bpf: Fix test_attach_probe 2019-12-19 16:14:08 +01:00
bpf_obj_id.c selftests/bpf: test_progs: remove asserts from subtests 2019-08-28 00:35:40 +02:00
bpf_tcp_ca.c bpf: tcp: Add bpf_cubic example 2020-01-22 16:30:10 -08:00
bpf_verif_scale.c selftests/bpf: Add a test for a large global function 2020-01-10 17:20:07 +01:00
btf_dump.c selftests/bpf: Convert test_btf_dump into test_progs test 2019-10-09 15:38:36 -07:00
cgroup_attach_autodetach.c selftests/bpf: Convert test_cgroup_attach to prog_tests 2019-12-19 21:22:26 -08:00
cgroup_attach_multi.c selftests/bpf: Test BPF_F_REPLACE in cgroup_attach_multi 2019-12-19 21:22:26 -08:00
cgroup_attach_override.c selftests/bpf: Convert test_cgroup_attach to prog_tests 2019-12-19 21:22:26 -08:00
core_extern.c libbpf: Allow to augment system Kconfig through extra optional config 2019-12-18 17:33:36 -08:00
core_reloc.c selftests/bpf: Add flexible array relocation tests 2019-12-15 16:53:51 -08:00
cpu_mask.c selftests: Use consistent include paths for libbpf 2020-01-20 16:37:45 -08:00
fentry_fexit.c bpftool, selftests/bpf: Embed object file inside skeleton 2019-12-17 22:16:35 -08:00
fentry_test.c selftests/bpf: Initialize duration variable before using 2020-01-24 11:05:45 +01:00
fexit_bpf2bpf.c selftests/bpf: Initialize duration variable before using 2020-01-24 11:05:45 +01:00
fexit_stress.c selftests/bpf: Add stress test for maximum number of progs 2019-11-15 23:43:53 +01:00
fexit_test.c selftests/bpf: Initialize duration variable before using 2020-01-24 11:05:45 +01:00
flow_dissector_load_bytes.c selftests/bpf: add flow dissector bpf_skb_load_bytes helper test 2019-04-23 18:36:34 +02:00
flow_dissector_reattach.c selftests/bpf: Restore the netns after flow dissector reattach test 2019-10-17 12:10:16 -07:00
flow_dissector.c selftests/bpf: remove wrong nhoff in flow dissector test 2019-08-28 00:39:43 +02:00
get_stack_raw_tp.c selftests/bpf: test_progs: remove global fail/success counts 2019-08-28 00:35:40 +02:00
global_data.c selftests/bpf: test_progs: remove global fail/success counts 2019-08-28 00:35:40 +02:00
kfree_skb.c selftest/bpf: Simple test for fentry/fexit 2019-11-15 23:42:46 +01:00
l4lb_all.c selftests/bpf: test_progs: remove global fail/success counts 2019-08-28 00:35:40 +02:00
map_lock.c selftests/bpf: test_progs: remove asserts from subtests 2019-08-28 00:35:40 +02:00
mmap.c bpftool, selftests/bpf: Embed object file inside skeleton 2019-12-17 22:16:35 -08:00
obj_name.c selftests: bpf: break up test_progs - misc 2019-03-02 11:10:40 -08:00
perf_buffer.c selftests: Use consistent include paths for libbpf 2020-01-20 16:37:45 -08:00
pinning.c selftests/bpf: Add tests for automatic map unpinning on load failure 2019-11-10 19:26:30 -08:00
pkt_access.c selftests/bpf: test_progs: remove global fail/success counts 2019-08-28 00:35:40 +02:00
pkt_md_access.c selftests/bpf: test_progs: remove global fail/success counts 2019-08-28 00:35:40 +02:00
probe_user.c libbpf: Add generic bpf_program__attach() 2019-12-15 15:58:04 -08:00
prog_run_xattr.c selftests: bpf: break up test_progs - misc 2019-03-02 11:10:40 -08:00
queue_stack_map.c selftests/bpf: test_progs: remove global fail/success counts 2019-08-28 00:35:40 +02:00
raw_tp_writable_reject_nbd_invalid.c selftests: bpf: test writable buffers in raw tps 2019-04-26 19:04:19 -07:00
raw_tp_writable_test_run.c selftests: bpf: test writable buffers in raw tps 2019-04-26 19:04:19 -07:00
rdonly_maps.c libbpf: Expose BPF program's function name 2019-12-15 15:58:05 -08:00
reference_tracking.c libbpf: Make DECLARE_LIBBPF_OPTS macro strictly a variable declaration 2019-10-22 21:35:03 +02:00
section_names.c selftests/bpf: Move test_section_names into test_progs and fix it 2019-10-23 10:06:46 -07:00
select_reuseport.c selftests: bpf: Reset global state between reuseport test runs 2020-01-24 22:12:13 +01:00
send_signal.c selftests/bpf: Fix test_progs send_signal flakiness with nmi mode 2020-01-16 13:28:57 -08:00
signal_pending.c selftests: bpf: test_progs: initialize duration in singal_pending test 2019-03-07 10:46:25 +01:00
skb_ctx.c bpf: Allow to change skb mark in test_run 2019-12-18 17:05:58 -08:00
skeleton.c libbpf: Put Kconfig externs into .kconfig section 2019-12-18 17:33:36 -08:00
sockmap_basic.c bpf: Selftests build error in sockmap_basic.c 2020-02-10 14:31:34 -08:00
sockopt_inherit.c selftests/bpf: test_progs: Don't leak server_fd in test_sockopt_inherit 2019-10-02 00:58:07 +02:00
sockopt_multi.c selftests/bpf: test_progs: convert test_sockopt_multi 2019-09-06 09:59:05 -07:00
sockopt_sk.c selftests/bpf: test_progs: convert test_sockopt_sk 2019-09-06 09:59:05 -07:00
sockopt.c selftests/bpf: test_progs: convert test_sockopt 2019-09-06 09:59:05 -07:00
spinlock.c selftests/bpf: test_progs: remove asserts from subtests 2019-08-28 00:35:40 +02:00
stacktrace_build_id_nmi.c selftests/bpf: Skip perf hw events test if the setup disabled it 2020-01-20 23:26:58 +01:00
stacktrace_build_id.c bpftool, selftests/bpf: Embed object file inside skeleton 2019-12-17 22:16:35 -08:00
stacktrace_map_raw_tp.c selftests/bpf: test_progs: remove global fail/success counts 2019-08-28 00:35:40 +02:00
stacktrace_map.c selftests/bpf: test_progs: remove global fail/success counts 2019-08-28 00:35:40 +02:00
tailcalls.c bpf, testing: Add various tail call test cases 2019-11-24 17:04:12 -08:00
task_fd_query_rawtp.c selftests/bpf: test_progs: remove global fail/success counts 2019-08-28 00:35:40 +02:00
task_fd_query_tp.c selftests/bpf: test_progs: remove global fail/success counts 2019-08-28 00:35:40 +02:00
tcp_estats.c selftests/bpf: test_progs: remove global fail/success counts 2019-08-28 00:35:40 +02:00
tcp_rtt.c selftests/bpf: test_progs: Don't leak server_fd in tcp_rtt 2019-10-02 00:56:46 +02:00
test_global_funcs.c selftests/bpf: Add unit tests for global functions 2020-01-10 17:20:07 +01:00
test_overhead.c selftests/bpf: Restore original comm in test_overhead 2020-01-09 08:42:07 -08:00
tp_attach_query.c selftests: bpf: initialize bpf_object pointers where needed 2019-05-09 15:53:56 -07:00
trampoline_count.c selftests/bpf: Fix trampoline_count.c selftest compilation warning 2020-02-04 00:08:49 +01:00
xdp_adjust_tail.c selftests/bpf: test_progs: remove global fail/success counts 2019-08-28 00:35:40 +02:00
xdp_bpf2bpf.c selftests/bpf: Add a test for attaching a bpf fentry/fexit trace to an XDP program 2020-01-15 13:22:25 -08:00
xdp_noinline.c selftests/bpf: test_progs: remove global fail/success counts 2019-08-28 00:35:40 +02:00
xdp_perf.c selftests: bpf: Add xdp_perf test 2019-12-13 13:09:32 -08:00
xdp.c selftests/bpf: test_progs: remove global fail/success counts 2019-08-28 00:35:40 +02:00