]> git.baikalelectronics.ru Git - kernel.git/commit
openvswitch: properly refcount vport-vxlan module
authorPaolo Abeni <pabeni@redhat.com>
Mon, 30 Nov 2015 11:31:43 +0000 (12:31 +0100)
committerDavid S. Miller <davem@davemloft.net>
Wed, 2 Dec 2015 16:50:59 +0000 (11:50 -0500)
commit6bb6097fd4d82ea352bfcf0b7d9aa62b7030b48a
tree0f299bcb43b700b7bfdab63a998ba4070613a649
parent1100e9c8c7beb0e79cb24d60e44f22db25a0df9e
openvswitch: properly refcount vport-vxlan module

After 8f83206ada5e, no refcount is maintained for the vport-vxlan module.
This allows the userspace to remove such module while vport-vxlan
devices still exist, which leads to later oops.

v1 -> v2:
 - move vport 'owner' initialization in ovs_vport_ops_register()
   and make such function a macro

Fixes: 8f83206ada5e ("openvswitch: Use regular VXLAN net_device device")
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/openvswitch/vport-geneve.c
net/openvswitch/vport-gre.c
net/openvswitch/vport.c
net/openvswitch/vport.h