aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv4/tcp_output.c
diff options
context:
space:
mode:
authorAlexei Starovoitov <[email protected]>2020-01-21 00:53:48 +0000
committerDaniel Borkmann <[email protected]>2020-01-22 22:04:53 +0000
commit7805fe843964f81f98592bf580b9cd736ac4ad4c (patch)
tree99bc088a4cd4e27b6c5befcbae2ade0ea72a7f1d /net/ipv4/tcp_output.c
parentlibbpf: Add support for program extensions (diff)
downloadkernel-7805fe843964f81f98592bf580b9cd736ac4ad4c.tar.gz
kernel-7805fe843964f81f98592bf580b9cd736ac4ad4c.zip
selftests/bpf: Add tests for program extensions
Add program extension tests that build on top of fexit_bpf2bpf tests. Replace three global functions in previously loaded test_pkt_access.c program with three new implementations: int get_skb_len(struct __sk_buff *skb); int get_constant(long val); int get_skb_ifindex(int val, struct __sk_buff *skb, int var); New function return the same results as original only if arguments match. new_get_skb_ifindex() demonstrates that 'skb' argument doesn't have to be first and only argument of BPF program. All normal skb based accesses are available. Signed-off-by: Alexei Starovoitov <[email protected]> Signed-off-by: Daniel Borkmann <[email protected]> Acked-by: John Fastabend <[email protected]> Acked-by: Andrii Nakryiko <[email protected]> Acked-by: Toke Høiland-Jørgensen <[email protected]> Link: https://lore.kernel.org/bpf/[email protected]
Diffstat (limited to 'net/ipv4/tcp_output.c')
0 files changed, 0 insertions, 0 deletions