[Devel] Re: [patch -mm 08/17] nsproxy: add hashtable

Eric W. Biederman ebiederm at xmission.com
Wed Dec 13 10:53:56 PST 2006


Cedric Le Goater <clg at fr.ibm.com> writes:

> Eric W. Biederman wrote:
>> 
>> What we don't have is a fast pid to namespace transfer. But that is just
>> an extra pointer in struct pid.  Really that is a trivial patch.
>> Giving every namespace a pid pointer in struct pid takes a little more
>> space then I would like but it is not a big deal.
>
> I'm not sure I understand how you want to do this. 
>
> Let me try : you would add a 'struct pid pid' field to all namespaces and
> assign that 'pid' field  with the struct pid of the task creating the
> namespace ? 

Yes a struct pid *pid field, that we did the proper reference counting
on.

As for which pid to assign, that is a little trickier.  The struct pid
of the task creating the namespace is the obvious choice and that will
always work for clone.  For unshare that would only work if we added
the restriction you can't unshare if someone already has used that pid
for that kind of namespace.

Eric
_______________________________________________
Containers mailing list
Containers at lists.osdl.org
https://lists.osdl.org/mailman/listinfo/containers




More information about the Devel mailing list