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] [thread-next>] [day] [month] [year] [list]
Message-ID: <4AE9A7AA.70107@trash.net>
Date:	Thu, 29 Oct 2009 15:33:14 +0100
From:	Patrick McHardy <kaber@...sh.net>
To:	Eric Dumazet <eric.dumazet@...il.com>
CC:	"David S. Miller" <davem@...emloft.net>,
	Linux Netdev List <netdev@...r.kernel.org>
Subject: Re: [PATCH 4/6] vlan: Optimize multiple unregistration

Eric Dumazet wrote:
> Patrick McHardy a écrit :
>> How about this? I moved the code back into vlan_device_event() since
>> its now only a very minimal change to the original code.
>>
>> vlan-orig.diff contains the diff between the original code and the
>> code after this patch for reference.
>>
>>
> 
> I have no problem with this solution, but I wonder why you re-added the curious
> 
> 			/* unregistration of last vlan destroys group, abort
> 			 * afterwards */
> 			if (grp->nr_vlans == 1)
> 				i = VLAN_GROUP_ARRAY_LEN;
> 
> 			unregister_vlan_dev(vlandev, &list);
> 
> while doing
> 
> 	unregister_vlan_dev(vlandev, &list);
> 	if (grp->nr_vlans == 0)
> 		break;
> 
> seems more natural :)

Indeed, but unregister_vlan_dev() destroys the group once the
count has reached zero, so we must not access it after that.
--
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