aboutsummaryrefslogtreecommitdiffstats
path: root/tools/testing/selftests/bpf/prog_tests/prog_tests_framework.c
diff options
context:
space:
mode:
authorJakub Sitnicki <jakub@cloudflare.com>2025-08-14 11:59:29 +0200
committerMartin KaFai Lau <martin.lau@kernel.org>2025-08-18 10:29:42 -0700
commit0e74eb4d57f00e6103ac23ce2312766c25ad88f6 (patch)
tree0111af7f9e6a13efc354f93a1d2f5d26cd9edd29 /tools/testing/selftests/bpf/prog_tests/prog_tests_framework.c
parentbpf: Enable read/write access to skb metadata through a dynptr (diff)
downloadlinux-0e74eb4d57f00e6103ac23ce2312766c25ad88f6.tar.gz
linux-0e74eb4d57f00e6103ac23ce2312766c25ad88f6.zip
selftests/bpf: Cover verifier checks for skb_meta dynptr type
dynptr for skb metadata behaves the same way as the dynptr for skb data with one exception - writes to skb_meta dynptr don't invalidate existing skb and skb_meta slices. Duplicate those the skb dynptr tests which we can, since bpf_dynptr_from_skb_meta kfunc can be called only from TC BPF, to cover the skb_meta dynptr verifier checks. Also add a couple of new tests (skb_data_valid_*) to ensure we don't invalidate the slices in the mentioned case, which are specific to skb_meta dynptr. Signed-off-by: Jakub Sitnicki <jakub@cloudflare.com> Signed-off-by: Martin KaFai Lau <martin.lau@kernel.org> Reviewed-by: Jesse Brandeburg <jbrandeburg@cloudflare.com> Link: https://patch.msgid.link/20250814-skb-metadata-thru-dynptr-v7-3-8a39e636e0fb@cloudflare.com
Diffstat (limited to 'tools/testing/selftests/bpf/prog_tests/prog_tests_framework.c')
0 files changed, 0 insertions, 0 deletions