On Fri, Mar 7, 2014 at 11:52 AM, Pritesh Kothari (pritkoth) <pritk...@cisco.com> wrote: > Hi Pravin, > >>> >>> if (type > OVS_TUNNEL_KEY_ATTR_MAX) { >>> @@ -388,11 +390,16 @@ static int ipv4_tun_from_nlattr(const struct nlattr >>> *attr, >>> case OVS_TUNNEL_KEY_ATTR_CSUM: >>> tun_flags |= TUNNEL_CSUM; >>> break; >>> + case OVS_TUNNEL_KEY_ATTR_NSP: >>> + nsp = htonl(be32_to_cpu(nla_get_be32(a)) << 8); >>> + tun_flags |= TUNNEL_NSP; >>> + break; >>> default: >>> return -EINVAL; >>> } >>> } >>> >> I have not looked at entire patch but just noticed this. If you only >> going to support NSP over vxlan only we should check if this packet is >> for vxlan or add support of NSP for all tunneling protocols. > > yes actually the check does exists, here is the snippet from around line 445 > of the patch: > Can you copy paste that code snippet? I could not find it.
What I meant was, If NSP is set for tunnel then check if output actions sends packet to vxlan. > @@ -68,7 +69,8 @@ static void vxlan_rcv(struct vxlan_sock *vs, struct sk_buff > *skb, __be32 vx_vni) > - ovs_flow_tun_key_init(&tun_key, iph, key, TUNNEL_KEY); > + ovs_flow_tun_key_init(&tun_key, iph, key, nsp, > + TUNNEL_KEY | TUNNEL_NSP); > > so when we receive packet over vxlan with nsp, we flag it. > > Regards, > Pritesh _______________________________________________ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev