Messages in this thread | | | From | Linus Torvalds <> | Date | Mon, 1 Apr 2019 09:15:00 -0700 | Subject | Re: [PATCH v2 0/5] pid: add pidfd_open() |
| |
On Mon, Apr 1, 2019 at 9:07 AM Jonathan Kowalski <bl0pbl33p@gmail.com> wrote: > > With the POLLHUP model on a simple pidfd, you'd know when the process > you were referring to is dead (and one can map POLLPRI to dead and > POLLHUP to zombie, etc).
Adding ->poll() to the pidfd should be easy. Again, it would be trivially be made to work for the directory fd you get from /proc/<pid> too.
Yeah, yeah, pollable directories are odd, but the vfs layer doesn't care about things like "is this a directory or not". It will just call the f_op->poll() method.
Linus
| |