summaryrefslogtreecommitdiffstats
path: root/tools/include
diff options
context:
space:
mode:
authorWilliam Tu <u9012063@gmail.com>2017-08-07 13:14:42 -0700
committerDavid S. Miller <davem@davemloft.net>2017-08-08 18:12:50 -0700
commit996139e801fd145bc44b70b4f4bfa621d626f948 (patch)
treee1ff71d5bae264c2b80ea196accb8e54e23827e1 /tools/include
parentea6404c841011a1ed7b6eac64621d5f96e8b7183 (diff)
downloadlinux-996139e801fd145bc44b70b4f4bfa621d626f948.tar.bz2
selftests: bpf: add a test for XDP redirect
Add test for xdp_redirect by creating two namespaces with two veth peers, then forward packets in-between. Signed-off-by: William Tu <u9012063@gmail.com> Cc: Daniel Borkmann <daniel@iogearbox.net> Cc: John Fastabend <john.fastabend@gmail.com> Acked-by: Daniel Borkmann <daniel@iogearbox.net> Acked-by: John Fastabend <john.fastabend@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'tools/include')
-rw-r--r--tools/include/uapi/linux/bpf.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/tools/include/uapi/linux/bpf.h b/tools/include/uapi/linux/bpf.h
index 1579cab49717..8d9bfcca3fe4 100644
--- a/tools/include/uapi/linux/bpf.h
+++ b/tools/include/uapi/linux/bpf.h
@@ -592,7 +592,8 @@ union bpf_attr {
FN(get_socket_uid), \
FN(set_hash), \
FN(setsockopt), \
- FN(skb_adjust_room),
+ FN(skb_adjust_room), \
+ FN(redirect_map),
/* integer value in 'imm' field of BPF_CALL instruction selects which helper
* function eBPF program intends to call