]> git.baikalelectronics.ru Git - kernel.git/commit
vxlan: fix missing options_len update on RX with collect metadata
authorDaniel Borkmann <daniel@iogearbox.net>
Wed, 2 Mar 2016 01:32:08 +0000 (02:32 +0100)
committerDavid S. Miller <davem@davemloft.net>
Thu, 3 Mar 2016 22:10:31 +0000 (17:10 -0500)
commit5197710fa240c24ef6259e9a84137dfc61cebc46
treef259b09b3a9da9d1ac26da99a1daf1eb3441c4da
parent426c8d8e43c8a95362763545bfc4673be0aea670
vxlan: fix missing options_len update on RX with collect metadata

When signalling to metadata consumers that the metadata_dst entry
carries additional GBP extension data for vxlan (TUNNEL_VXLAN_OPT),
the dst's vxlan_metadata information is populated, but options_len
is left to zero. F.e. in ovs, ovs_flow_key_extract() checks for
options_len before extracting the data through ip_tunnel_info_opts_get().

Geneve uses ip_tunnel_info_opts_set() helper in receive path, which
sets options_len internally, vxlan however uses ip_tunnel_info_opts(),
so when filling vxlan_metadata, we do need to update options_len.

Fixes: dbc4257b7af2 ("ip-tunnel: Use API to access tunnel metadata options.")
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Acked-by: Thomas Graf <tgraf@suug.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/vxlan.c