bpf: Selftests, sockmap test prog run without setting cgroup
authorJohn Fastabend <john.fastabend@gmail.com>
Wed, 13 May 2020 19:13:46 +0000 (12:13 -0700)
committerDaniel Borkmann <daniel@iogearbox.net>
Sat, 16 May 2020 00:56:49 +0000 (02:56 +0200)
commit13a5f3ffd202f73f1d0c2ed36dd66a0cd891e61a
tree3cbeae64b5576dbb1365881328437a30ffbb7166
parentd79a32129b21296f1dce1bd9d703826853bb63a6
bpf: Selftests, sockmap test prog run without setting cgroup

Running test_sockmap with arguments to specify a test pattern requires
including a cgroup argument. Instead of requiring this if the option is
not provided create one

This is not used by selftest runs but I use it when I want to test a
specific test. Most useful when developing new code and/or tests.

Signed-off-by: John Fastabend <john.fastabend@gmail.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Reviewed-by: Jakub Sitnicki <jakub@cloudflare.com>
Link: https://lore.kernel.org/bpf/158939722675.15176.6294210959489131688.stgit@john-Precision-5820-Tower
tools/testing/selftests/bpf/test_sockmap.c