xref: /linux/tools/testing/selftests/net/rds/README.txt (revision 2fe3c78a2c26dd5ee811024a1b7d6cfb4d654319)
1RDS self-tests
2==============
3
4These scripts provide a coverage test for RDS-TCP by creating two
5network namespaces and running rds packets between them. A loopback
6network is provisioned with optional probability of packet loss or
7corruption. A workload of 50000 hashes, each 64 characters in size,
8are passed over an RDS socket on this test network. A passing test means
9the RDS-TCP stack was able to recover properly.  The provided config.sh
10can be used to compile the kernel with the necessary gcov options.  The
11kernel may optionally be configured to omit the coverage report as well.
12
13USAGE:
14	run.sh [-d logdir] [-l packet_loss] [-c packet_corruption]
15	       [-u packet_duplcate]
16
17OPTIONS:
18	-d	Log directory.  Defaults to tools/testing/selftests/net/rds/rds_logs
19
20	-l	Simulates a percentage of packet loss
21
22	-c	Simulates a percentage of packet corruption
23
24	-u	Simulates a percentage of packet duplication.
25
26EXAMPLE:
27
28    # Create a suitable gcov enabled .config
29    tools/testing/selftests/net/rds/config.sh -g
30
31    # Alternatly create a gcov disabled .config
32    tools/testing/selftests/net/rds/config.sh
33
34    # build the kernel
35    vng --build  --config tools/testing/selftests/net/config
36
37    # launch the tests in a VM
38    vng -v --rwdir ./ --run . --user root --cpus 4 -- \
39        "export PYTHONPATH=tools/testing/selftests/net/; tools/testing/selftests/net/rds/run.sh"
40
41An HTML coverage report will be output in tools/testing/selftests/net/rds/rds_logs/coverage/.
42