]> git.baikalelectronics.ru Git - kernel.git/commit
selftests/net: relax cpu affinity requirement in msg_zerocopy test
authorWillem de Bruijn <willemb@google.com>
Wed, 5 Aug 2020 08:40:45 +0000 (04:40 -0400)
committerDavid S. Miller <davem@davemloft.net>
Wed, 5 Aug 2020 19:25:35 +0000 (12:25 -0700)
commitc82f990eb19d9097f47c58549ac52fdfb72a8122
tree272f7907786f9def338b4f93b08e92444413ffb8
parenteee053893381f002e8649db6a0fbc7bb2bf52fbe
selftests/net: relax cpu affinity requirement in msg_zerocopy test

The msg_zerocopy test pins the sender and receiver threads to separate
cores to reduce variance between runs.

But it hardcodes the cores and skips core 0, so it fails on machines
with the selected cores offline, or simply fewer cores.

The test mainly gives code coverage in automated runs. The throughput
of zerocopy ('-z') and non-zerocopy runs is logged for manual
inspection.

Continue even when sched_setaffinity fails. Just log to warn anyone
interpreting the data.

Fixes: 5e00bbb5e46b ("test: add msg_zerocopy test")
Reported-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Willem de Bruijn <willemb@google.com>
Acked-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
tools/testing/selftests/net/msg_zerocopy.c