Received: by 2002:a25:f815:0:0:0:0:0 with SMTP id u21csp2229832ybd; Mon, 24 Jun 2019 02:58:46 -0700 (PDT) X-Google-Smtp-Source: APXvYqy1K+IRKIC6HS+1C7IflKnJvWq+uuyrLj5sD332Eru10txZSajOMAvv0MS3bZ8DAcSepqvf X-Received: by 2002:a65:404a:: with SMTP id h10mr32760308pgp.262.1561370326327; Mon, 24 Jun 2019 02:58:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1561370326; cv=none; d=google.com; s=arc-20160816; b=mc1jQdgtNe3KPXdQCzOSYfU++8FWMGwQnu+Gp7TuCmCqP61tv+EzYsHDHdcgyVkfm9 jQAZ/XE3tr/Y2op8bJBzmCghncxeXAMI/I48kuCTm38dkMReD26Sx607MhdYvLhJnzft TRoNcFMGunRr28dHhaFpmpBbP+2nh5mxvXcXsthDW/nPLk1Fv4uXGviv3b2Ti+GucEBL w93T2BiS7b45krX7uuEYoTDV+Nk/Hviz7Jc+TQESpAXq1Jrqy1Pm8dchGsE2PdMKvqOz uhlNBB16+bzF12rQQHeWGulFDKYEHe+mNUJ2ZJwWdeTW/Isk2T155i7m7KaPUaSi156J Hyfw== 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=RrWOGQLSuFaCXRqkCQw1GpNc+s0Q4CseKG3Kvw44Shw=; b=YTDQGggigOUANc9GBSYupCDk2XtIg0F9cpUkRikm5gZrSodiL70R3leKG1oCgyVhgq GVoL8YZr9+YYf0l1eosizfuViKv0WqX75gDnDSsZlNl9uFuzJp633EvJbK7tRxVkAEf3 fpZAXjwUl/reBsuRYw5xC32jLcapjCf+D42FieduePZdDvqj8aldmyA23WRPPdiDuD30 rq6+glLY+DVVp5O3ek97m2/q1x8RSXly6wVTpXpe8HrdK9fRQNjgNXoqL/05sV+2cfd3 kjomQENZrY6mLzC5EFlkFjK6mJv8L5oFtNNE+ygqFHooDwlafOAo1XkU1Cux0lDn1+IB qO7A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@brauner.io header.s=google header.b=DCoHB6xY; 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 h69si5565450pgc.230.2019.06.24.02.58.30; Mon, 24 Jun 2019 02:58:46 -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=@brauner.io header.s=google header.b=DCoHB6xY; 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 S1728434AbfFXJwx (ORCPT + 99 others); Mon, 24 Jun 2019 05:52:53 -0400 Received: from mail-wm1-f67.google.com ([209.85.128.67]:39755 "EHLO mail-wm1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727926AbfFXJwx (ORCPT ); Mon, 24 Jun 2019 05:52:53 -0400 Received: by mail-wm1-f67.google.com with SMTP id z23so12676360wma.4 for ; Mon, 24 Jun 2019 02:52:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=brauner.io; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=RrWOGQLSuFaCXRqkCQw1GpNc+s0Q4CseKG3Kvw44Shw=; b=DCoHB6xY3eLz3XYEk/MV+TWa102/ZzqKZrFVovG3pkCyujl3srGzZ+ARKgTQxPanYW HUeKGkI+ZfsdglHWhyFQmJzSvGb/cTYqqGpCEgogSY8hUZ7drOQjiVcEyyOEPCTCP8I2 vVWUJ096GVTPHP/VDpYYWRZt2bSNoeYfhPpr+KhJksGY8bzzDoZ7S++oEzmTOw3sxaHQ lE8K5a0tYztxEOGlLq29IZMaydA2om2Rx5gMp8UV7vLy2gLYop8k4+Kvdjh9CAYoMnXe xpV1h6T2RLstvmX3T7OLjfbvzsP5cwmVJH2fQzCEkxvxs1HvLST6xJQWUMJyu6Du+axD SIxA== 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=RrWOGQLSuFaCXRqkCQw1GpNc+s0Q4CseKG3Kvw44Shw=; b=ML2t42XAfY1S9jJR0+abL5GBZl5qsyw0RUo6QCcm80EDXBPgEhobOHNhd9nJrMR+0V ALGLhsQ2kwaxq/BpjCYuIZ2VLNljsJoCrFa29ZhkqtloX6EXvs1rFHIcG/GVWrZ8f+VY e2OYwJKe7tBOEpA1LPcFJhyhlz4N+w7E2oiCmh7ATjTesg0OhhhKjjkhleFqYq6MOAU1 viqgmgaPcJ/Cq8SVjOeBWYQOe0IZURTGxj1+ZimGhuFoeKZAy//U1iRQWWz9spJOKDqC tzwt8jxTASvuFfqGxtovGHnH1iSXrmAHvb6KLJAacaQgn68G33iwE0uQkwIcaUA6B7ue xvWg== X-Gm-Message-State: APjAAAX9ruM2X/qyCqUeI4WIRtC+Ngi42Lq5yC4Lc+qEBnbVjBmhQMOf 2zpgIQ2QecpCojcJ7ytdQAni/w== X-Received: by 2002:a7b:c751:: with SMTP id w17mr15904467wmk.127.1561369971469; Mon, 24 Jun 2019 02:52:51 -0700 (PDT) Received: from brauner.io ([212.91.227.56]) by smtp.gmail.com with ESMTPSA id w7sm5866229wmc.46.2019.06.24.02.52.51 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Mon, 24 Jun 2019 02:52:51 -0700 (PDT) Date: Mon, 24 Jun 2019 11:52:50 +0200 From: Christian Brauner To: "Dmitry V. Levin" Cc: Jann Horn , Oleg Nesterov , Arnd Bergmann , linux-api@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] samples: make pidfd-metadata fail gracefully on older kernels Message-ID: <20190624095250.wtl5t5cewo7scyby@brauner.io> References: <20190620103105.cdxgqfelzlnkmblv@brauner.io> <20190620110037.GA4998@altlinux.org> <20190620111036.asi3mbcv4ax5ekrw@brauner.io> <20190621170613.GA26182@altlinux.org> <20190621221339.6yj4vg4zexv4y2j7@brauner.io> <20190623113230.GC20697@altlinux.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20190623113230.GC20697@altlinux.org> User-Agent: NeoMutt/20180716 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sun, Jun 23, 2019 at 02:32:30PM +0300, Dmitry V. Levin wrote: > On Sat, Jun 22, 2019 at 12:13:39AM +0200, Christian Brauner wrote: > [...] > > Out of curiosity: what makes the new flag different than say > > CLONE_NEWCGROUP or any new clone flag that got introduced? > > CLONE_NEWCGROUP too would not be detectable apart from the method I gave > > you above; same for other clone flags. Why are you so keen on being able > > to detect this flag when other flags didn't seem to matter that much. > > I wasn't following uapi changes closely enough those days. ;) (Seriously, you had one job. :) I'm joking of course.) What you want makes sense to me overall. This way userspace can decide easier whether to manage a process through a pidfd or needs to fallback to a pid. Christian