bpf, ixgbe: add meta data support
authorDaniel Borkmann <daniel@iogearbox.net>
Mon, 25 Sep 2017 00:25:55 +0000 (02:25 +0200)
committerDavid S. Miller <davem@davemloft.net>
Tue, 26 Sep 2017 20:36:44 +0000 (13:36 -0700)
commit366a88fe2f40d6772985ec78cdd34df7f109bb88
tree3fa94accf68450c409d7532a68872e84d2f3aefc
parent65d88fd0baaa5c9def9383ac696097911d4ceb73
bpf, ixgbe: add meta data support

Implement support for transferring XDP meta data into skb for
ixgbe driver; before calling into the program, xdp.data_meta points
to xdp.data, where on program return with pass verdict, we call
into skb_metadata_set().

We implement this for the default ixgbe_build_skb() variant. For the
ixgbe_construct_skb() that is used when legacy-rx buffer mananagement
mode is turned on via ethtool, I found that XDP gets 0 headroom, so
neither xdp_adjust_head() nor xdp_adjust_meta() can be used with this.
Just add a comment with explanation for this operating mode.

Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Acked-by: Alexei Starovoitov <ast@kernel.org>
Acked-by: John Fastabend <john.fastabend@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/intel/ixgbe/ixgbe_main.c