summaryrefslogtreecommitdiff
path: root/net/netfilter/nft_tunnel.c
diff options
context:
space:
mode:
authorXin Long <lucien.xin@gmail.com>2019-12-13 16:53:07 +0800
committerPablo Neira Ayuso <pablo@netfilter.org>2019-12-17 22:58:26 +0100
commit2149f36dbd44f2d6bf5357e5d096205b92cd854a (patch)
treeb15b712dd04774005409050a0256c8ba2ad77622 /net/netfilter/nft_tunnel.c
parent0705f95c332081036d85f26691e9d3cd7d901c31 (diff)
netfilter: nft_tunnel: also dump ERSPAN_VERSION
This is not necessary, but it'll be easier to parse in userspace, also given that other places like act_tunnel_key, cls_flower and ip_tunnel_core are also doing so. Signed-off-by: Xin Long <lucien.xin@gmail.com> Reviewed-by: Simon Horman <simon.horman@netronome.com> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'net/netfilter/nft_tunnel.c')
-rw-r--r--net/netfilter/nft_tunnel.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/net/netfilter/nft_tunnel.c b/net/netfilter/nft_tunnel.c
index 6538895466e0..b3a9b10ff43d 100644
--- a/net/netfilter/nft_tunnel.c
+++ b/net/netfilter/nft_tunnel.c
@@ -479,6 +479,9 @@ static int nft_tunnel_opts_dump(struct sk_buff *skb,
htonl(opts->u.vxlan.gbp)))
return -1;
} else if (opts->flags & TUNNEL_ERSPAN_OPT) {
+ if (nla_put_be32(skb, NFTA_TUNNEL_KEY_ERSPAN_VERSION,
+ htonl(opts->u.erspan.version)))
+ return -1;
switch (opts->u.erspan.version) {
case ERSPAN_VERSION:
if (nla_put_be32(skb, NFTA_TUNNEL_KEY_ERSPAN_V1_INDEX,