Re: [PATCH v2 1/4] pidfd: support PIDFD_NONBLOCK in pidfd_open()

2020-09-03 Thread Josh Triplett
On Wed, Sep 02, 2020 at 12:21:27PM +0200, Christian Brauner wrote: > Introduce PIDFD_NONBLOCK to support non-blocking pidfd file descriptors. > > Ever since the introduction of pidfds and more advanced async io various > programming languages such as Rust have grown support for async event > libra

Re: [PATCH v2 1/4] pidfd: support PIDFD_NONBLOCK in pidfd_open()

2020-09-03 Thread Christian Brauner
On Thu, Sep 03, 2020 at 04:58:09PM +0200, Oleg Nesterov wrote: > Christian, off-topic question... > > On 09/02, Christian Brauner wrote: > > > > -static int pidfd_create(struct pid *pid) > > +static int pidfd_create(struct pid *pid, unsigned int flags) > > { > > int fd; > > > > fd = anon_

Re: [PATCH v2 1/4] pidfd: support PIDFD_NONBLOCK in pidfd_open()

2020-09-03 Thread Oleg Nesterov
Christian, off-topic question... On 09/02, Christian Brauner wrote: > > -static int pidfd_create(struct pid *pid) > +static int pidfd_create(struct pid *pid, unsigned int flags) > { > int fd; > > fd = anon_inode_getfd("[pidfd]", &pidfd_fops, get_pid(pid), > -

Re: [PATCH v2 1/4] pidfd: support PIDFD_NONBLOCK in pidfd_open()

2020-09-03 Thread Oleg Nesterov
On 09/02, Christian Brauner wrote: > > -static int pidfd_create(struct pid *pid) > +static int pidfd_create(struct pid *pid, unsigned int flags) > { > int fd; > > fd = anon_inode_getfd("[pidfd]", &pidfd_fops, get_pid(pid), > - O_RDWR | O_CLOEXEC); > +

[PATCH v2 1/4] pidfd: support PIDFD_NONBLOCK in pidfd_open()

2020-09-02 Thread Christian Brauner
Introduce PIDFD_NONBLOCK to support non-blocking pidfd file descriptors. Ever since the introduction of pidfds and more advanced async io various programming languages such as Rust have grown support for async event libraries. These libraries are created to help build epoll-based event loops aroun