linux/tools/testing/selftests/net
Willem de Bruijn 75f0139fd6 selftests/net: add packet socket packet_snd test
Add regression tests for PF_PACKET transmission using packet_snd.

The TPACKET ring interface has tests for transmission and reception.
This is an initial stab at the same for the send call based interface.

Packets are sent over loopback, then read twice. The entire packet is
read from another packet socket and compared. The packet is also
verified to arrive at a UDP socket for protocol conformance.

The test sends a packet over loopback, testing the following options
(not the full cross-product):

- SOCK_DGRAM
- SOCK_RAW
- vlan tag
- qdisc bypass
- bind() and sendto()
- virtio_net_hdr
- csum offload (NOT actual csum feature, ignored on loopback)
- gso

Besides these basic functionality tests, the test runs from a set
of bounds checks, positive and negative. Running over loopback, which
has dev->min_header_len, it cannot generate variable length hhlen.

Signed-off-by: Willem de Bruijn <willemb@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2018-06-04 09:50:01 -04:00
..
forwarding selftests: forwarding: mirror_gre_bridge_1d_vlan: Add STP test 2018-06-01 14:11:04 -04:00
.gitignore selftests/net: add packet socket packet_snd test 2018-06-04 09:50:01 -04:00
config selftests/net: Add missing config options for PMTU tests 2018-05-25 15:11:21 -04:00
fib_rule_tests.sh selftests: net: initial fib rule tests 2018-05-23 15:14:12 -04:00
fib_tests.sh selftests: fib_tests: Add prefix route tests with metric 2018-05-29 10:12:46 -04:00
fib-onlink-tests.sh selftests: Add multipath tests for onlink flag 2018-03-22 12:37:05 -04:00
in_netns.sh selftests/net: fix in_netns.sh script 2018-03-07 12:26:05 -05:00
Makefile selftests/net: add packet socket packet_snd test 2018-06-04 09:50:01 -04:00
msg_zerocopy.c selftests/net: reap zerocopy completions passed up as ancillary data. 2018-02-27 14:19:11 -05:00
msg_zerocopy.sh selftests/net: enable msg_zerocopy test 2018-06-04 09:49:39 -04:00
netdevice.sh License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
pmtu.sh selftests: pmtu: Minimum MTU for vti6 is 68 2018-04-27 14:33:19 -04:00
psock_fanout.c selftests/net: ignore background traffic in psock_fanout 2018-02-23 12:47:05 -05:00
psock_lib.h selftests/net: Fixes psock_fanout CBPF test case 2017-04-20 15:39:19 -04:00
psock_snd.c selftests/net: add packet socket packet_snd test 2018-06-04 09:50:01 -04:00
psock_snd.sh selftests/net: add packet socket packet_snd test 2018-06-04 09:50:01 -04:00
psock_tpacket.c tools: psock_tpacket: block Rx until socket filter has been added and socket has been bound to loopback. 2017-01-05 15:03:41 -05:00
reuseaddr_conflict.c selftest: add a reuseaddr test 2017-09-19 14:09:26 -06:00
reuseport_bpf_cpu.c License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
reuseport_bpf_numa.c selftests: net: reuseport_bpf_numa: don't fail if no numa support 2018-05-23 12:21:02 +02:00
reuseport_bpf.c bpf: fix rlimit in reuseport net selftest 2018-02-09 14:46:37 -05:00
reuseport_dualstack.c License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
rtnetlink.sh selftests: add xfrm state-policy-monitor to rtnetlink.sh 2018-04-17 13:15:29 +02:00
run_afpackettests selftests/net: ignore background traffic in psock_fanout 2018-02-23 12:47:05 -05:00
run_netsocktests License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
socket.c License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
tcp_inq.c selftest: add test for TCP_INQ 2018-05-01 18:56:29 -04:00
tcp_mmap.c selftests: net: tcp_mmap must use TCP_ZEROCOPY_RECEIVE 2018-04-29 21:29:55 -04:00
test_bpf.sh License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
udpgso_bench_rx.c selftests: udp gso benchmark 2018-04-26 15:09:52 -04:00
udpgso_bench_tx.c selftests: udp gso benchmark 2018-04-26 15:09:52 -04:00
udpgso_bench.sh selftests: udp gso benchmark 2018-04-26 15:09:52 -04:00
udpgso.c selftests/net: udpgso: test small gso_size boundary conditions 2018-06-04 09:49:39 -04:00
udpgso.sh selftests: udp gso with corking 2018-04-26 15:09:52 -04:00