lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CALnjE+pW-1R5jV+rwXJPZu=ANi+VB0885NDnA8TiTiiDXRphiQ@mail.gmail.com>
Date:	Mon, 5 Aug 2013 08:58:09 -0700
From:	Pravin Shelar <pshelar@...ira.com>
To:	Stephen Hemminger <stephen@...workplumber.org>
Cc:	netdev@...r.kernel.org
Subject: Re: [PATCH net-next v6 3/8] vxlan: Add vxlan recv demux.

On Sun, Aug 4, 2013 at 2:45 PM, Stephen Hemminger
<stephen@...workplumber.org> wrote:
> On Thu,  1 Aug 2013 11:44:49 -0700
> Pravin B Shelar <pshelar@...ira.com> wrote:
>
>> +static struct vxlan_sock *vxlan_sock_add(struct net *net, __be16 port,
>> +                                      vxlan_rcv_t *rcv)
>>  {
>>       struct vxlan_net *vn = net_generic(net, vxlan_net_id);
>>       struct vxlan_sock *vs;
>>
>> -     vxlan_socket_create(net, port);
>> +     vxlan_socket_create(net, port, rcv);
>>
>>       spin_lock(&vn->sock_lock);
>>       vs = vxlan_find_sock(net, port);
>> -     if (vs)
>> -             atomic_inc(&vs->refcnt);
>> -     else
>> +     if (vs) {
>> +             if (vs->rcv == rcv)
>> +                     atomic_inc(&vs->refcnt);
>> +             else
>> +                     vs = ERR_PTR(-EBUSY);
>> +     }
>> +     spin_unlock(&vn->sock_lock);
>> +
>
> I think the ref counting needs to be the same for the
> kernel and OVS handling of a VXLAN.

Ref counting is same for ovs and vxlan.
In this patch ovs and vxlan module vxlan-rcv function pointers are
checked for port sharing.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ