]> git.karo-electronics.de Git - linux-beck.git/commitdiff
bpf: add XDP_TX xdp_action for direct forwarding
authorBrenden Blanco <bblanco@plumgrid.com>
Tue, 19 Jul 2016 19:16:53 +0000 (12:16 -0700)
committerDavid S. Miller <davem@davemloft.net>
Wed, 20 Jul 2016 04:46:32 +0000 (21:46 -0700)
XDP enabled drivers must transmit received packets back out on the same
port they were received on when a program returns this action.

Signed-off-by: Brenden Blanco <bblanco@plumgrid.com>
Acked-by: Alexei Starovoitov <ast@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/uapi/linux/bpf.h

index a51786566c2f118ce50480cb8b5ae7b5c01c83e0..2b7076f5b5ad3465d7f30ba898771621acbd13a5 100644 (file)
@@ -449,6 +449,7 @@ enum xdp_action {
        XDP_ABORTED = 0,
        XDP_DROP,
        XDP_PASS,
+       XDP_TX,
 };
 
 /* user accessible metadata for XDP packet hook