Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp6159882yba; Thu, 11 Apr 2019 13:22:25 -0700 (PDT) X-Google-Smtp-Source: APXvYqza5T7YlVjqfLTb8sS8sl+IwA68mOl9dKgbyT9HaWgtsD7l7z5TPrAoNox9YJUoyl3grjno X-Received: by 2002:a62:ab12:: with SMTP id p18mr51563750pff.216.1555014145150; Thu, 11 Apr 2019 13:22:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1555014145; cv=none; d=google.com; s=arc-20160816; b=EfZZLZkdODPgJybxPtbMe/1khT99/fN/s0NjuHoEZq2P1tLU70i2esOY2oyjADo9eV uJ4E/CLWdMgBdCyTfj6n4aTKjAG7aQh+EsvrcPCMPk1UU6hHtK2VqiHd+zVpg3MLddX8 dgBmu+NRy33T2SsZ7WlV4DVs6XRfgWELTj1efcKIqb21ES06oznOCIqoirokv5svZCel PKI6h+d2/5dUt8bbLN7OeYkxe0E1UOkbg0esSKkZiK32zjN3L6I76rUnLVWVWXLgf0GK 1lmHJqeI72a39Symc/jma1hXBo8rxx2Zo9AuJ9hqkx5wtzFbTT0+iWMNt38aq7lqjzXG gjMA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=Z1/+beueiWsmz6a7TBUTMwuhhscPHS19VKrRN/IMS0U=; b=igwY+CG4lyG0kFe6l20o4mR/De6eGnUJiGnafjtLX27FN9zaHUuAohQTT1El9vwMRf iDtOCiAZ6ZPqbpSmfaIAqsgRGKNC+vwoy3KO+M8ftthrdifj9PDRMEAcO4d+FFTMwWqq DGPMI6yhLpDJFNH8nH1Uuh/qUeZ9MVtkD+itUrOTdv98WnO0cQ3rNim4bXWrfIeNOPQh KCEnMx3Ls3cH0TcV9W/TC7nq7KFwDlibPmE7tJypnaDwQCaQeITEifvxRK/ZI8yJfZe8 woruDKF0H5aAKMwIc3iLze2Hp+iFpdFWZutpxS8sQT/7SPemWYRbFwjKMFr2s4fZ0zWJ PyzA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@joelfernandes.org header.s=google header.b="aw/y4BML"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 71si12368848plc.91.2019.04.11.13.22.09; Thu, 11 Apr 2019 13:22:25 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@joelfernandes.org header.s=google header.b="aw/y4BML"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726878AbfDKUUK (ORCPT + 99 others); Thu, 11 Apr 2019 16:20:10 -0400 Received: from mail-pl1-f194.google.com ([209.85.214.194]:45257 "EHLO mail-pl1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726615AbfDKUUJ (ORCPT ); Thu, 11 Apr 2019 16:20:09 -0400 Received: by mail-pl1-f194.google.com with SMTP id bf11so3918188plb.12 for ; Thu, 11 Apr 2019 13:20:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=joelfernandes.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=Z1/+beueiWsmz6a7TBUTMwuhhscPHS19VKrRN/IMS0U=; b=aw/y4BMLUJFg3fdAfFIw5zmt9yb1JolbZxeS57967jUjrq6SBOsZuzyeiMwrH1e0KA kwkh1BVeP0HsE4+9oqeETXp2/wPEzy6NT2tlDkRE90hAuJXvdjfhXuB41eBvszc5ncux AWNMjzmWXi0Lu9eF/aSYP8eV7KdKU2B5ozZDo= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=Z1/+beueiWsmz6a7TBUTMwuhhscPHS19VKrRN/IMS0U=; b=bThYVuhdXTIOgj2WvPsa3vz8db8RiyJSxWND1jKK3tPyuSvzzkEEj/B2BFKIhYh5ry Dr4GGoUbQyQlM0onMBHnVLG/gzriSdZ6Bo9xVuzwlPAYPiJH8VPED01a4/r7ttK1FJAK gVG0+wTLZZs3SVZ2LmHnYEhL9Wr/6RkxkdtgDZ2B5qOYQoZTmCBVVJ7cxtN63t6BBL9H Wio9zPvUsM0NIShP01EZq+F9EIsYWFnYYndGfcVeAz+KOWiG6glzd4GKOUi5V+WdqCnr pNjtPqdEaS+BZIyvMotLANzpqK7RQRBYvyBNRaMZaVi4noFAzntFPJG0KNqf93wJD58m VqJA== X-Gm-Message-State: APjAAAVcxWEHX+9/NubePqjGkC6qzwNIhsHJa2fDC5i1uQbEzeNLV+Ao gPRGccKJPVErMEybPrdKxQWlXTXwUBM= X-Received: by 2002:a17:902:1621:: with SMTP id g30mr21026345plg.168.1555014008316; Thu, 11 Apr 2019 13:20:08 -0700 (PDT) Received: from localhost ([2620:15c:6:12:9c46:e0da:efbf:69cc]) by smtp.gmail.com with ESMTPSA id j67sm69927804pfc.72.2019.04.11.13.20.06 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Thu, 11 Apr 2019 13:20:07 -0700 (PDT) Date: Thu, 11 Apr 2019 16:20:06 -0400 From: Joel Fernandes To: Christian Brauner Cc: linux-kernel@vger.kernel.org, luto@amacapital.net, rostedt@goodmis.org, dancol@google.com, jannh@google.com, surenb@google.com, torvalds@linux-foundation.org, Alexey Dobriyan , Al Viro , Andrei Vagin , Andrew Morton , Arnd Bergmann , "Eric W. Biederman" , Kees Cook , linux-fsdevel@vger.kernel.org, linux-kselftest@vger.kernel.org, Michal Hocko , Nadav Amit , Oleg Nesterov , Serge Hallyn , Shuah Khan , Stephen Rothwell , Taehee Yoo , Tejun Heo , Thomas Gleixner , kernel-team@android.com, Tycho Andersen Subject: Re: [PATCH RFC 1/2] Add polling support to pidfd Message-ID: <20190411202006.GA130334@google.com> References: <20190411175043.31207-1-joel@joelfernandes.org> <20190411200059.GA75190@google.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Apr 11, 2019 at 10:02:32PM +0200, Christian Brauner wrote: > On April 11, 2019 10:00:59 PM GMT+02:00, Joel Fernandes wrote: > >On Thu, Apr 11, 2019 at 01:50:42PM -0400, Joel Fernandes (Google) > >wrote: > >> pidfd are /proc/pid directory file descriptors referring to a task > >group > >> leader. Android low memory killer (LMK) needs pidfd polling support > >to > >> replace code that currently checks for existence of /proc/pid for > >> knowing a process that is signalled to be killed has died, which is > >both > >> racy and slow. The pidfd poll approach is race-free, and also allows > >the > >> LMK to do other things (such as by polling on other fds) while > >awaiting > >> the process being killed to die. > > > >It appears to me that the "pidfd" now will be an anon inode fd, and not > >based > >on /proc/, based on discussions with Linus. So I'll rework the patches > >accordingly. However that is relatively independent of this patch so > >this > >version can also be reviewed before I send out the reworked version. > > Thank you very much, Joel. > I'm off this week and traveling but I'll try to give it a look asap. > > Christian Sounds great to me, thanks a lot Christian. - Joel