diff options
author | Eyal Birger <eyal.birger@gmail.com> | 2018-04-24 17:50:30 +0300 |
---|---|---|
committer | Daniel Borkmann <daniel@iogearbox.net> | 2018-04-24 23:26:58 +0300 |
commit | 29a36f9eef30b7f008b722a753a84b314f981037 (patch) | |
tree | 9790a515413c05b19aa0eb988ef002a2cdb1dc05 /tools/testing/selftests/bpf/bpf_helpers.h | |
parent | 12bed760a78da6e12ac8252fec64d019a9eac523 (diff) | |
download | linux-29a36f9eef30b7f008b722a753a84b314f981037.tar.xz |
samples/bpf: extend test_tunnel_bpf.sh with xfrm state test
Add a test for fetching xfrm state parameters from a tc program running
on ingress.
Signed-off-by: Eyal Birger <eyal.birger@gmail.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Diffstat (limited to 'tools/testing/selftests/bpf/bpf_helpers.h')
-rw-r--r-- | tools/testing/selftests/bpf/bpf_helpers.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/tools/testing/selftests/bpf/bpf_helpers.h b/tools/testing/selftests/bpf/bpf_helpers.h index 9271576bdc8f..69d7b918e66a 100644 --- a/tools/testing/selftests/bpf/bpf_helpers.h +++ b/tools/testing/selftests/bpf/bpf_helpers.h @@ -98,7 +98,9 @@ static int (*bpf_bind)(void *ctx, void *addr, int addr_len) = (void *) BPF_FUNC_bind; static int (*bpf_xdp_adjust_tail)(void *ctx, int offset) = (void *) BPF_FUNC_xdp_adjust_tail; - +static int (*bpf_skb_get_xfrm_state)(void *ctx, int index, void *state, + int size, int flags) = + (void *) BPF_FUNC_skb_get_xfrm_state; /* llvm builtin functions that eBPF C program may use to * emit BPF_LD_ABS and BPF_LD_IND instructions |