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]
Date:	Sun, 11 May 2014 22:17:11 -0700
From:	Cong Wang <xiyou.wangcong@...il.com>
To:	"Eric W. Biederman" <ebiederm@...ssion.com>
Cc:	Stephen Hemminger <stephen@...workplumber.org>,
	Linux Kernel Network Developers <netdev@...r.kernel.org>,
	"David S. Miller" <davem@...emloft.net>,
	Cong Wang <cwang@...pensource.com>
Subject: Re: [Patch net] rtnetlink: call rtnl_lock_unregistering() in rtnl_link_unregister()

On Fri, May 9, 2014 at 4:05 PM, Eric W. Biederman <ebiederm@...ssion.com> wrote:
> Cong Wang <xiyou.wangcong@...il.com> writes:
>
>> On Fri, May 9, 2014 at 12:02 PM, Stephen Hemminger
>> <stephen@...workplumber.org> wrote:
>>> On Fri, 9 May 2014 11:10:36 -0700
>>> Cong Wang <xiyou.wangcong@...il.com> wrote:
>>>
>>>>
>>>> This can't be done without a macro (at least for me). Or
>>>> we have to duplicate the code.
>>>
>>> macro method is too ugly, figure out a better way.
>>
>> That's what I am going to do for -net-next. This patch is for -net,
>> it's an ugly but minimum change I can find.
>>
>> Of course, if you insist we should clean up it for -net as well,
>> I can do that.
>
> It would be no worse to rename the existing function
> rtnl_lock_unregistering_list
>
> And add a second function rtnl_lock_unregistering that does
> the same thing but uses the global list.
>
> Of course this begs the question what happens if the network
> device we want to destroy is a network namespace that is currently
> exiting and not on the global list.
>

OK, so we have to duplicate the code.

> It looks like we need to grab the net_mutex to get a state where network
> namespaces are not exiting...
>

Hmm, for me it looks like we need net_mutex only we change pernet ops,
here rtnl lock is enough. No?
--
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