Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit c6a5ba48 authored by Xin Long's avatar Xin Long Committed by Greg Kroah-Hartman
Browse files

netfilter: nft_tunnel: add the missing ERSPAN_VERSION nla_policy



[ Upstream commit 0705f95c332081036d85f26691e9d3cd7d901c31 ]

ERSPAN_VERSION is an attribute parsed in kernel side, nla_policy
type should be added for it, like other attributes.

Fixes: af308b94 ("netfilter: nf_tables: add tunnel support")
Signed-off-by: default avatarXin Long <lucien.xin@gmail.com>
Reviewed-by: default avatarSimon Horman <simon.horman@netronome.com>
Signed-off-by: default avatarPablo Neira Ayuso <pablo@netfilter.org>
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
parent 8a3bc6e3
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -218,6 +218,7 @@ static int nft_tunnel_obj_vxlan_init(const struct nlattr *attr,
}

static const struct nla_policy nft_tunnel_opts_erspan_policy[NFTA_TUNNEL_KEY_ERSPAN_MAX + 1] = {
	[NFTA_TUNNEL_KEY_ERSPAN_VERSION]	= { .type = NLA_U32 },
	[NFTA_TUNNEL_KEY_ERSPAN_V1_INDEX]	= { .type = NLA_U32 },
	[NFTA_TUNNEL_KEY_ERSPAN_V2_DIR]		= { .type = NLA_U8 },
	[NFTA_TUNNEL_KEY_ERSPAN_V2_HWID]	= { .type = NLA_U8 },