Received: by 2002:a17:90a:1609:0:0:0:0 with SMTP id n9csp2050288pja; Thu, 9 Apr 2020 13:09:43 -0700 (PDT) X-Google-Smtp-Source: APiQypLFCjrsZhykp6/rBzyT3LZbUIqhsUWA6eexkjaAqnd5y3xNqB+T7+2qt1ajAFQ2wtfRSiD2 X-Received: by 2002:ac8:6919:: with SMTP id e25mr1161078qtr.151.1586462983011; Thu, 09 Apr 2020 13:09:43 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1586462983; cv=none; d=google.com; s=arc-20160816; b=sqxUvLf2UtnFV0W5odUKPgX4E4RTt25q8SMs6k1QDxQX/GwxGOVYcYgRzP/WVz+j/T ieTOw+xb4T7WS4gRJFtOPs/+/EqlYcuOSSVprovqf37lkxPKMM8RcCI0R/re8Uq7Yidn TFbzmGFqqtbnpBDP6scGWRgaMne20borNuNSL/K8YL3Ge4OHO0k996mc7Oy6/mCMbYIM u1+Ly2Mn246+XYi4plqCLHsBG+A7V0dOEC+i2wvVDC9NMFBmXtZ/Zw6lisPd40oYmHWS +GjQuqmNTDll/KQtS0ebfr7mzNALXdQAuCIz9qbqftjQJrKjHptpC//kJHeBUR3sT5R2 62RA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=uNxSVyIGdaSTr0lywTyA2DSe6ffIyDbX6ysZP8sCQHU=; b=TZzQ6n39YxLn9BzL2hthLWMhuADnq96Q+TNNvg+GAW7uq7b4/EBnaeS6vxphBPzP4g lG/B2e6XME9TUhTHQ2m4nhVZ8+atlNC671NowlXfQ93XQN1ocvs+6l22dJPXGabsztrq 01uCENd5nuhYbGfE36HKArRRmYqatEGGe3EiiHUqKTvXSJmwmmBSJKvG2ocFhKh6JDHF xADkEKFxeGa+kFtWTBCw3XKIoqtxOsDp8NBBSy+jMpbNZAYsrlVjQZLFm9Ujos22ZHsW H+svIESxe+EdQcEIuIcjZgtsedWXZ331Wfjc65s6+dRs4HcXKUMqvp0DckHM/xEz+05h g3UQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linux-foundation.org header.s=google header.b=VHdaI9F2; 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 r3si6247825qvh.79.2020.04.09.13.09.27; Thu, 09 Apr 2020 13:09:42 -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=@linux-foundation.org header.s=google header.b=VHdaI9F2; 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 S1726890AbgDIUEz (ORCPT + 99 others); Thu, 9 Apr 2020 16:04:55 -0400 Received: from mail-lj1-f194.google.com ([209.85.208.194]:33665 "EHLO mail-lj1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726638AbgDIUEz (ORCPT ); Thu, 9 Apr 2020 16:04:55 -0400 Received: by mail-lj1-f194.google.com with SMTP id q22so1091445ljg.0 for ; Thu, 09 Apr 2020 13:04:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux-foundation.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=uNxSVyIGdaSTr0lywTyA2DSe6ffIyDbX6ysZP8sCQHU=; b=VHdaI9F2b94QbcEW3FTvBCL1X8t5Kxv3xHYG1y/drJJib7CVtztF9I6Na7ybMVJ827 u5LxYnpsHzUd6oa4D6rh0TGzUqKsASlIAeq8+IIshnJ+XRaDMSMBTMcSjsclg32h+X9h 0P8y05H/E0Y5AgTPYk48DrvCyc6FnUlPR197g= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=uNxSVyIGdaSTr0lywTyA2DSe6ffIyDbX6ysZP8sCQHU=; b=VqKTYCx+wPFklX0HcFkqb7HPeHBLc+2deCjShrTTEe02LPtclAuVpyO+YVyNxJfpJo edcVidfnghTiByOdQakxcuC8JuJ5VJU54oEcIl1veLfPpJDK1nBO2r5jVBsC7tID4Sk6 3k74ww9v+weNj1c8ls/LtWtg9FU6GxwFJhDpwccf+q0FN49yxZwBAw6ZCdPp1SCoae8U Bxlalv9Gy4gkBLslVuGGEdWtJ3ZePybp4/IsVdfBZzmvr3+unTbF084snZ71pLkL6C5d viW4+sQQK0Krc0PNXs0wtNsLw8c60wxfncFey0w9XQVP111XILvPGrZaS+wep3z65wNw 23iA== X-Gm-Message-State: AGi0PuYg9hfC+xpd2haX1UODoy/DsFAVJUGeOyWf1tiXc0yRx2x2JB5f U3/DbtLXw7h7THV+R+cId1kfKDxK3eo= X-Received: by 2002:a2e:9c4:: with SMTP id 187mr903993ljj.89.1586462692438; Thu, 09 Apr 2020 13:04:52 -0700 (PDT) Received: from mail-lj1-f173.google.com (mail-lj1-f173.google.com. [209.85.208.173]) by smtp.gmail.com with ESMTPSA id 83sm46345lfn.30.2020.04.09.13.04.51 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 09 Apr 2020 13:04:51 -0700 (PDT) Received: by mail-lj1-f173.google.com with SMTP id r24so1060245ljd.4 for ; Thu, 09 Apr 2020 13:04:51 -0700 (PDT) X-Received: by 2002:a2e:8652:: with SMTP id i18mr922513ljj.265.1586462690881; Thu, 09 Apr 2020 13:04:50 -0700 (PDT) MIME-Version: 1.0 References: <87blobnq02.fsf@x220.int.ebiederm.org> <87lfnda3w3.fsf@x220.int.ebiederm.org> <87blo45keg.fsf@x220.int.ebiederm.org> <87v9maxb5q.fsf@x220.int.ebiederm.org> <87y2r4so3i.fsf@x220.int.ebiederm.org> <87wo6or3pg.fsf@x220.int.ebiederm.org> In-Reply-To: From: Linus Torvalds Date: Thu, 9 Apr 2020 13:04:34 -0700 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [GIT PULL] Please pull proc and exec work for 5.7-rc1 To: Bernd Edlinger Cc: "Eric W. Biederman" , Waiman Long , Ingo Molnar , Will Deacon , Linux Kernel Mailing List , Alexey Gladkov , Oleg Nesterov Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Apr 9, 2020 at 12:57 PM Bernd Edlinger wrote: > > The use case where this may happen with strace > when you call strace with lots of -p arguments, > and one of them is a bomb. strace stuck. Yeah, so from a convenience angle I do agree that it would be nicer to just not count dead threads. You can test that by just moving the /* Don't bother with already dead threads */ if (t->exit_state) continue; test in zap_other_threads() to above the count++; line instead. NOTE! That is *NOT* the correct true fix. I'm just suggesting that you try if it fixes that particular test-case (I did not try it myself - because .. lazy) If Oleg agrees that we could take the approach that we can share a signal struct with dead threads, we'd also need to change the accounting to do that notify_count not when the signal struct is unlinked, but when exit_state is first set. I'm not convinced that's the right solution, but I do agree that it's annoying how easily strace can get stuck, since one of the main uses for strace is for debugging nasty situations. Linus