On 06/27/2018 06:39 AM, Jakub Kicinski wrote: > From: Pieter Jansen van Vuuren <[email protected]> > > Check the tunnel option type stored in tunnel flags when creating options > for tunnels. Thereby ensuring we do not set geneve, vxlan or erspan tunnel > options on interfaces that are not associated with them. > > Make sure all users of the infrastructure set correct flags, for the BPF > helper we have to set all bits to keep backward compatibility. > > Signed-off-by: Pieter Jansen van Vuuren <[email protected]> > Signed-off-by: Jakub Kicinski <[email protected]> > --- > CC: Daniel Borkmann <[email protected]> > > v2: > - use __be16 for dst_opt_type in net/openvswitch/flow_netlink.c (build bot).
Looks good to me, and yes in BPF case a mask like TUNNEL_OPTIONS_PRESENT is right approach since this is opaque info and solely defined by the BPF prog that is using the generic helper. Thanks, Daniel
