OpenVZ Forum


Home » Mailing lists » Devel » [PATCH] usb: Fixup usb so it uses struct pid
Re: [PATCH] usb: Fixup usb so it uses struct pid [message #16654 is a reply to message #16651] Sun, 10 September 2006 18:12 Go to previous messageGo to previous message
Pete Zaitcev is currently offline  Pete Zaitcev
Messages: 1
Registered: September 2006
Junior Member
On Sat, 09 Sep 2006 22:42:10 -0600, ebiederm@xmission.com (Eric W. Biederman) wrote:

> The problem by remember a user space process by it's pid it is
> possible that the process will exit, pid wrap around will occur and a
> different process will appear in it's place.

... which is completely all right in this case. We used to have an
implementation which tried to hold onto the task_struct and that sucked.
It is only possible for the task to disappear without notifying devio
under very special conditions only, which involve forking with parent
exiting. In other words, even a buggy application won't trigger this
without deliberately trying. And when it happens, uid checks make sure
that other users are not affected.

>  Holding a reference
> to a struct pid avoid that problem, and paves the way
> for implementing a pid namespace.

That may be useful.

The patch itself seems straightforward if we can trust your struct
pid thingies. If OpenVZ people approve, I don't mind.

-- Pete
_______________________________________________
Containers mailing list
Containers@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/containers
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: [PATCH] vt: Rework the console spawning variables.
Next Topic: [RFC][PATCH 0/2] user namespace [try #2]
Goto Forum:
  


Current Time: Tue Aug 05 06:32:14 GMT 2025

Total time taken to generate the page: 1.02117 seconds