kernel-ark/net/8021q
Pavel Emelyanov 3f03e38789 [VLAN]: Fix potential race in vlan_cleanup_module vs vlan_ioctl_handler.
The vlan module cleanup function starts with

	vlan_netlink_fini();
	vlan_ioctl_set(NULL);

The first call removes all the vlan devices and
the second one closes the vlan ioctl.

AFAIS there's a tiny race window between these two
calls - after rtnl unregistered all the vlans, but
the ioctl handler isn't set to NULL yet, user can
manage to call this ioctl and create one vlan device,
and that this function will later BUG_ON seeing
non-emply hashes.

I think, that we must first close the vlan ioctl
and only after this remove all the vlans with the
vlan_netlink_fini() call.

Signed-off-by: Pavel Emelyanov <xemul@openvz.org>
Acked-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-12-11 02:45:32 -08:00
..
Kconfig
Makefile
vlan_dev.c [VLAN]: Fix nested VLAN transmit bug 2007-11-29 22:16:41 +11:00
vlan_netlink.c
vlan.c [VLAN]: Fix potential race in vlan_cleanup_module vs vlan_ioctl_handler. 2007-12-11 02:45:32 -08:00
vlan.h [VLAN]: Allow setting mac address while device is up 2007-11-10 21:52:35 -08:00
vlanproc.c
vlanproc.h