On 10/04/2018 12:56 PM, Pablo Neira Ayuso wrote: > On Thu, Oct 04, 2018 at 11:25:33AM +0200, Daniel Borkmann wrote: >> On 10/04/2018 02:03 AM, Pablo Neira Ayuso wrote: [...] >>> diff --git a/net/openvswitch/flow_netlink.c b/net/openvswitch/flow_netlink.c >>> index a70097ecf33c..1ee2509534df 100644 >>> --- a/net/openvswitch/flow_netlink.c >>> +++ b/net/openvswitch/flow_netlink.c >>> @@ -2602,6 +2602,7 @@ static int validate_and_copy_set_tun(const struct nlattr *attr, >>> ovs_tun->tun_dst = tun_dst; >>> >>> tun_info = &tun_dst->u.tun_info; >>> + tun_info->type = IP_TUNNEL_TYPE_UNSPEC; >>> tun_info->mode = IP_TUNNEL_INFO_TX; >>> if (key.tun_proto == AF_INET6) >>> tun_info->mode |= IP_TUNNEL_INFO_IPV6; >>> >> >> If so then this should also be made explicit IP_TUNNEL_TYPE_UNSPEC in BPF code >> since all these tunnel types are supported there as well. > > Are you refering to proper initialization? I can see a memset() there > for the ip_tunnel_info structure, which is implicitly setting > tun_info->type to zero, ie. IP_TUNNEL_TYPE_UNSPEC. > > I can also make it explicit there if you prefer. Yeah that would be my preference as otherwise we might miss future changes there. Thanks, Daniel