Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp4427623imu; Fri, 30 Nov 2018 17:26:30 -0800 (PST) X-Google-Smtp-Source: AFSGD/VRDh/fyfSY5pmpUNyHbLloCg1F6mfEvRDjmqOhiDNxnB5mvg3cMW71PMWfDq/Zv8VDWa09 X-Received: by 2002:a63:e711:: with SMTP id b17mr6414901pgi.363.1543627590280; Fri, 30 Nov 2018 17:26:30 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1543627590; cv=none; d=google.com; s=arc-20160816; b=j5O4kn+yuU9g4bcZtMiC36fdn0rOqGHmGPukroUHE0MTWrmeWnegxvtGvMMRnebzSo 7E5yPsM06dULVmRbfKMRHiVWxhUGOntrrL2GkDgQi4MZaUWEHXFIJB2//33O3BzsCS3H J6nKpMHjJKsQJCDcLT4xfJis3sTm/mLgK5dU6oKZwRjwRyNYiR5MAzwlGneW+T0RgXuq 0CxX/wbNZDaICL5tCKdZPaXpRj/RxzIoyO0S0o5KLpoEZI5jEEvFNzQclwimGjXlYhKz bkWo3vU+FY1bi6zkbpWqIR9oFLcBqi0SEdVe2KWr9hvBZ3gsyo9tfvfXMscg2ZD4d0aW mAow== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:from:cc:to:subject :content-transfer-encoding:mime-version:references:in-reply-to :user-agent:date:dkim-signature; bh=wp5WpQaUj8L83+/r3AKv1KvjDv7nhf3IntrUC6vo1ig=; b=aVVFL0Z0iXv8qZ0C1fgut7JnnvwdJrpPdC/XShJgGkMDUZ+5+KvcPOz2tQ/BVH8p0l itwf/jrbQETCl+dy1rn4I+pEimPfrTZsUvMyrEOsGT32A2Gj28eegDAaJBt1pEFifHdO GNzcmm8wbvMolITd/rknaVW7em1/zWzBcTPaUlKk09uL8NH8accL1EasaFVW3NOmfQq9 6keIvvjrtsPT729sy/sjfnsjrOl6CSmKPR3cEQEAKe1OLOwEQ4jCiLUAj7uVp1NxGVft BjrKi02WL1CGupr266Vm6mdRgpOGj5SYsq9EnO6R6kyVRv4dueGuSCnJmpJDNp46kjG9 Bsog== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@brauner.io header.s=google header.b=KCuUtnNN; 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 u188si6332217pfb.232.2018.11.30.17.26.15; Fri, 30 Nov 2018 17:26:30 -0800 (PST) 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=fail header.i=@brauner.io header.s=google header.b=KCuUtnNN; 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 S1726595AbeLAMgu (ORCPT + 99 others); Sat, 1 Dec 2018 07:36:50 -0500 Received: from mail-io1-f68.google.com ([209.85.166.68]:44986 "EHLO mail-io1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726719AbeLAMgt (ORCPT ); Sat, 1 Dec 2018 07:36:49 -0500 Received: by mail-io1-f68.google.com with SMTP id r200so6030706iod.11 for ; Fri, 30 Nov 2018 17:25:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=brauner.io; s=google; h=date:user-agent:in-reply-to:references:mime-version :content-transfer-encoding:subject:to:cc:from:message-id; bh=wp5WpQaUj8L83+/r3AKv1KvjDv7nhf3IntrUC6vo1ig=; b=KCuUtnNNOyAHdtIjyphgpdlvzC9ejr5oF3HGdzP/O3rHuFnrS+yzWKVDUBUqyBnNOZ 73t2x/RRBKBkG5Iri7whnbnPqk5lcRcWld36NrDTdFwKfDbg4xd8bZWhiOXvf5ogjASq mtXQ+4+OovHCos7YRuLZIgYTsZ7JOasTEPjP3t5GQ/wmCbRLBrzvm8fBoqavLaCDAruS CPp0wJkab+C73ssOtR4PyPm8Q9JqfPgswq9970RfpPUdCG/rhTBp2L2Ws7aTQQKRPCv+ cnGShbnFnNbksLCdi27QOn7rfwN97i9oiq2mgeUVYEWpNXRlbBOC1YnwGz+1DTJqgOIN Gl+Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:user-agent:in-reply-to:references :mime-version:content-transfer-encoding:subject:to:cc:from :message-id; bh=wp5WpQaUj8L83+/r3AKv1KvjDv7nhf3IntrUC6vo1ig=; b=oV+OIpG2PhMYGs1Md15U0ixEXo3WgdFt2tC8JrtJnhOgNPKluOaPh8GHxahnWpPfRK OYoYZQsunKQ1QRcAged2l8GBrmA4IO6s4lMKhTVsvCZr1xMKAkw/zxgCFGS23AaxOCy5 UhYdPpT8YvcQyA+KEXwGSsJ4Dakmd6hxUDCbxStDI+hp8qYS5V+rNEUJsF20mYndYefH cvbGZVqluR7ujTrTexvs/Qw+q1UW4fPd9yfEYhw33n4zjvL85IhbfJ3G1Yl8aGKu4HEl DNPqqer5zdA03+iY9kKOkxEI4K13xUXqQroAPg37pcuchRiI6SM4/FFK6F+L9jfiEgo1 dIuQ== X-Gm-Message-State: AA+aEWYtxwXttZGlr9HBHy90cxrJwAQu0XQMrIa0Ohri9vkl5h7Kfgxu B2KImbEjg3c5CcOG3hE5w4+VlQ== X-Received: by 2002:a5d:870c:: with SMTP id u12mr6679411iom.168.1543627533453; Fri, 30 Nov 2018 17:25:33 -0800 (PST) Received: from [26.67.58.27] ([172.56.12.18]) by smtp.gmail.com with ESMTPSA id e10sm2847246ioa.65.2018.11.30.17.25.24 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 30 Nov 2018 17:25:32 -0800 (PST) Date: Sat, 01 Dec 2018 14:25:10 +1300 User-Agent: K-9 Mail for Android In-Reply-To: References: <20181120105124.14733-1-christian@brauner.io> <87in0g5aqo.fsf@oldenburg.str.redhat.com> <36323361-90BD-41AF-AB5B-EE0D7BA02C21@amacapital.net> <993B98AC-51DF-4131-AF7F-7DA2A7F485F1@brauner.io> <20181129195551.woe2bl3z3yaysqb6@brauner.io> <6E21165F-2C76-4877-ABD9-0C86D55FD6AA@amacapital.net> <20181129213458.4h44dpg6ltqow4k4@brauner.io> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Subject: Re: [PATCH v2] signal: add procfd_signal() syscall To: Arnd Bergmann CC: Andy Lutomirski , Andy Lutomirski , Florian Weimer , "Eric W . Biederman" , Linux Kernel Mailing List , "Serge E. Hallyn" , Jann Horn , Andrew Morton , Oleg Nesterov , cyphar@cyphar.com, Al Viro , Linux FS-devel Mailing List , Linux API , Daniel Colascione , Tim Murray , linux-man@vger.kernel.org, Kees Cook From: Christian Brauner Message-ID: <7D934AED-82E4-4DC3-8CCB-973680316B60@brauner.io> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On November 30, 2018 10:40:49 AM GMT+13:00, Arnd Bergmann = wrote: >On Thu, Nov 29, 2018 at 10:35 PM Christian Brauner > wrote: >> On Thu, Nov 29, 2018 at 10:02:13PM +0100, Arnd Bergmann wrote: >> > On Thu, Nov 29, 2018 at 9:14 PM Andy Lutomirski > wrote: >> > >> > Is the current procfd_signal() proposal (under whichever name) >sufficient >> > to correctly implement both sys_rt_sigqueueinfo() and >sys_rt_tgsigqueueinfo()? >> >> Yes, I see no reason why not=2E My idea is to extend it - after we have >a >> basic version in - to also work with: >> /proc//task/ >> If I'm not mistaken this should be sufficient to get >rt_tgsigqueueinfo=2E >> The thread will be uniquely identified by the tid descriptor and no >> combination of /proc/ and /proc//task/ is needed=2E Does >> that sound reasonable? > >Yes=2E So it would currently replace rt_gsigqueueinfo() but >not rt_tgsigqueueinfo(), and could be extended to do both >afterwards, without making the interface ugly in any form? Yes=2E :) > >I suppose we can always add more flags if needed, and you >already ensure that flags is zero for the moment=2E Yep=2E > >> > Can we implement sys_rt_sigtimedwait() based on signalfd()? >> > >> > If yes, that would leave waitid(), which already needs a >replacement >> > for y2038, and that should then also return a signalfd_siginfo=2E >> > My current preference for waitid() would be to do a version that >> > closely resembles the current interface, but takes a >signalfd_siginfo >> > and a __kernel_timespec based rusage replacement (possibly >> > two of them to let us map wait6), but does not operate on procfd or >> > take a signal mask=2E That would require yet another syscall, but I >> > don't think I can do that before we want to have the set of y2038 >> > safe syscalls=2E >> >> All sounds reasonable to me but that's not a blocker for the current >> syscall though, is it? > >I'd like to at least understand about sys_rt_sigtimedwait() before >we go on, so we all know what's coming, and document the >plans in the changelog=2E > >waitid() probably remains on my plate anyway, and I hope understand >where we're at with it=2E > > Arnd