Linux kernel mirror (for testing)
git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel
os
linux
1# SPDX-License-Identifier: GPL-2.0
2# Makefile for net selftests
3
4CFLAGS += -Wall -Wl,--no-as-needed -O2 -g
5CFLAGS += -I../../../../usr/include/ $(KHDR_INCLUDES)
6# Additional include paths needed by kselftest.h
7CFLAGS += -I../
8
9TEST_PROGS := \
10 altnames.sh \
11 amt.sh \
12 arp_ndisc_evict_nocarrier.sh \
13 arp_ndisc_untracked_subnets.sh \
14 bareudp.sh \
15 big_tcp.sh \
16 bind_bhash.sh \
17 bpf_offload.py \
18 broadcast_ether_dst.sh \
19 broadcast_pmtu.sh \
20 busy_poll_test.sh \
21 cmsg_ip.sh \
22 cmsg_so_mark.sh \
23 cmsg_so_priority.sh \
24 cmsg_time.sh \
25 drop_monitor_tests.sh \
26 fcnal-ipv4.sh \
27 fcnal-ipv6.sh \
28 fcnal-other.sh \
29 fdb_flush.sh \
30 fdb_notify.sh \
31 fib-onlink-tests.sh \
32 fib_nexthop_multiprefix.sh \
33 fib_nexthop_nongw.sh \
34 fib_nexthops.sh \
35 fib_rule_tests.sh \
36 fib_tests.sh \
37 fin_ack_lat.sh \
38 fq_band_pktlimit.sh \
39 gre_gso.sh \
40 gre_ipv6_lladdr.sh \
41 icmp.sh \
42 icmp_redirect.sh \
43 io_uring_zerocopy_tx.sh \
44 ioam6.sh \
45 ip6_gre_headroom.sh \
46 ip_defrag.sh \
47 ip_local_port_range.sh \
48 ipv6_flowlabel.sh \
49 ipv6_force_forwarding.sh \
50 ipv6_route_update_soft_lockup.sh \
51 l2_tos_ttl_inherit.sh \
52 l2tp.sh \
53 link_netns.py \
54 lwt_dst_cache_ref_loop.sh \
55 msg_zerocopy.sh \
56 nat6to4.sh \
57 ndisc_unsolicited_na_test.sh \
58 netdev-l2addr.sh \
59 netdevice.sh \
60 netns-name.sh \
61 netns-sysctl.sh \
62 nl_netdev.py \
63 pmtu.sh \
64 psock_snd.sh \
65 reuseaddr_ports_exhausted.sh \
66 reuseport_addr_any.sh \
67 route_hint.sh \
68 route_localnet.sh \
69 rps_default_mask.sh \
70 rtnetlink.py \
71 rtnetlink.sh \
72 rtnetlink_notification.sh \
73 run_afpackettests \
74 run_netsocktests \
75 rxtimestamp.sh \
76 sctp_vrf.sh \
77 skf_net_off.sh \
78 so_txtime.sh \
79 srv6_end_dt46_l3vpn_test.sh \
80 srv6_end_dt4_l3vpn_test.sh \
81 srv6_end_dt6_l3vpn_test.sh \
82 srv6_end_dx4_netfilter_test.sh \
83 srv6_end_dx6_netfilter_test.sh \
84 srv6_end_flavors_test.sh \
85 srv6_end_next_csid_l3vpn_test.sh \
86 srv6_end_x_next_csid_l3vpn_test.sh \
87 srv6_hencap_red_l3vpn_test.sh \
88 srv6_hl2encap_red_l2vpn_test.sh \
89 stress_reuseport_listen.sh \
90 tcp_fastopen_backup_key.sh \
91 test_bpf.sh \
92 test_bridge_backup_port.sh \
93 test_bridge_neigh_suppress.sh \
94 test_ingress_egress_chaining.sh \
95 test_neigh.sh \
96 test_so_rcv.sh \
97 test_vxlan_fdb_changelink.sh \
98 test_vxlan_mdb.sh \
99 test_vxlan_nh.sh \
100 test_vxlan_nolocalbypass.sh \
101 test_vxlan_under_vrf.sh \
102 test_vxlan_vnifiltering.sh \
103 tfo_passive.sh \
104 traceroute.sh \
105 txtimestamp.sh \
106 udpgro.sh \
107 udpgro_bench.sh \
108 udpgro_frglist.sh \
109 udpgro_fwd.sh \
110 udpgso.sh \
111 udpgso_bench.sh \
112 unicast_extensions.sh \
113 veth.sh \
114 vlan_bridge_binding.sh \
115 vlan_hw_filter.sh \
116 vrf-xfrm-tests.sh \
117 vrf_route_leaking.sh \
118 vrf_strict_mode_test.sh \
119 xfrm_policy.sh \
120# end of TEST_PROGS
121
122TEST_PROGS_EXTENDED := \
123 xfrm_policy_add_speed.sh \
124# end of TEST_PROGS_EXTENDED
125
126TEST_GEN_FILES := \
127 bind_bhash \
128 cmsg_sender \
129 fin_ack_lat \
130 hwtstamp_config \
131 io_uring_zerocopy_tx \
132 ioam6_parser \
133 ip_defrag \
134 ip_local_port_range \
135 ipsec \
136 ipv6_flowlabel \
137 ipv6_flowlabel_mgr \
138 msg_zerocopy \
139 nettest \
140 psock_fanout \
141 psock_snd \
142 psock_tpacket \
143 reuseaddr_ports_exhausted \
144 reuseport_addr_any \
145 rxtimestamp \
146 sctp_hello \
147 skf_net_off \
148 so_netns_cookie \
149 so_rcv_listener \
150 so_txtime \
151 socket \
152 stress_reuseport_listen \
153 tcp_fastopen_backup_key \
154 tcp_inq \
155 tcp_mmap \
156 tfo \
157 timestamping \
158 txring_overwrite \
159 txtimestamp \
160 udpgso \
161 udpgso_bench_rx \
162 udpgso_bench_tx \
163# end of TEST_GEN_FILES
164
165TEST_GEN_PROGS := \
166 bind_timewait \
167 bind_wildcard \
168 epoll_busy_poll \
169 ipv6_fragmentation \
170 proc_net_pktgen \
171 reuseaddr_conflict \
172 reuseport_bpf \
173 reuseport_bpf_cpu \
174 reuseport_bpf_numa \
175 reuseport_dualstack \
176 sk_bind_sendto_listen \
177 sk_connect_zero_addr \
178 sk_so_peek_off \
179 so_incoming_cpu \
180 tap \
181 tcp_port_share \
182 tls \
183 tun \
184# end of TEST_GEN_PROGS
185
186TEST_FILES := \
187 fcnal-test.sh \
188 in_netns.sh \
189 lib.sh \
190 settings \
191# end of TEST_FILES
192
193# YNL files, must be before "include ..lib.mk"
194YNL_GEN_FILES := busy_poller
195YNL_GEN_PROGS := netlink-dumps
196TEST_GEN_FILES += $(YNL_GEN_FILES)
197TEST_GEN_PROGS += $(YNL_GEN_PROGS)
198
199TEST_GEN_FILES += $(patsubst %.c,%.o,$(wildcard *.bpf.c))
200
201TEST_INCLUDES := forwarding/lib.sh
202
203include ../lib.mk
204
205# YNL build
206YNL_GENS := netdev
207include ynl.mk
208
209$(OUTPUT)/epoll_busy_poll: LDLIBS += -lcap
210$(OUTPUT)/reuseport_bpf_numa: LDLIBS += -lnuma
211$(OUTPUT)/tcp_mmap: LDLIBS += -lpthread -lcrypto
212$(OUTPUT)/tcp_inq: LDLIBS += -lpthread
213$(OUTPUT)/bind_bhash: LDLIBS += -lpthread
214$(OUTPUT)/io_uring_zerocopy_tx: CFLAGS += -I../../../include/
215
216include bpf.mk