Received: by 2002:a05:6a10:9848:0:0:0:0 with SMTP id x8csp773327pxf; Thu, 25 Mar 2021 13:46:11 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwUbPmO0uipzFax6ugTft6Im7IWB8rgku1Pnvpu1RIWkxyAP2xCmbryDZWinX64tolx8Vsh X-Received: by 2002:a50:fe06:: with SMTP id f6mr11304139edt.349.1616705171618; Thu, 25 Mar 2021 13:46:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1616705171; cv=none; d=google.com; s=arc-20160816; b=Dg+S8x8837AUjJN4r27Ht6NT2J8E4U2k8ofBl9JAAWQj48e6IGcY1USQt5YLdoC+zr ip9bm/RhW9lDYV4/NxItqitSils+EtLtqr8wq5XPxe3Ld6WEAVsn9ZicLCFbWCd1ueIe yEXGdJIe02JnP5sTCK/Rge0w8F16XDEQ8/43XoettSZZSzfj0Ajt3J0opsa2lTO4EcjB N1WqTiF8SEbBmN+c9mfxsWrsuPxAbgSGaLXz+I+3WvU8zohLeBocH6wPxIH9ix+sW/3o tMU9iUNfac7KSvR6Ub9xGYI7rHJQl1sggmiI31rxu4MwBifDX9a6DaYz/YwxdtrnXzn1 Q/sA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:dkim-signature; bh=4nRDXN5ZDY+7KKmxTUW+rmie0dxhoxA0kTC6dcBSgSo=; b=nHXnThaUEEuYxF03OWXjmjVlzbHmcwu/fCmObvyLZE/CbKifJhbx5YrJcyTM5Qzg+U G/dskiZXSNiAu6SDbj9q+ZxGUB/yw1Fs58d165OyJnXUiNeWO8A3zB9EsV09xvRQcXG+ LKxBL4v8MCO8zYJI2bKnPeufa0hz9saLbQAlfwXl98mi3wLeQakeEAo8M+ltgfubeeLy BYEeUpKYpiEU7ImD32f3YM/HHiXLagf9sbMpHD0TwBRBwjU4t34QYKOBbivVpWCwioJf fqfxFXOUCeD0wT1L6WYDqY1T8S7x5/foRxWLIdS8pJI+2d50KKKX54hdemP+x1sn0O5z /+Zw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel-dk.20150623.gappssmtp.com header.s=20150623 header.b=RbYghPy1; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id l3si5830892ejd.203.2021.03.25.13.45.48; Thu, 25 Mar 2021 13:46:11 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel-dk.20150623.gappssmtp.com header.s=20150623 header.b=RbYghPy1; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230341AbhCYUmr (ORCPT + 99 others); Thu, 25 Mar 2021 16:42:47 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47598 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230389AbhCYUmV (ORCPT ); Thu, 25 Mar 2021 16:42:21 -0400 Received: from mail-io1-xd2b.google.com (mail-io1-xd2b.google.com [IPv6:2607:f8b0:4864:20::d2b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 642ACC06174A for ; Thu, 25 Mar 2021 13:42:21 -0700 (PDT) Received: by mail-io1-xd2b.google.com with SMTP id z3so3225792ioc.8 for ; Thu, 25 Mar 2021 13:42:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel-dk.20150623.gappssmtp.com; s=20150623; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=4nRDXN5ZDY+7KKmxTUW+rmie0dxhoxA0kTC6dcBSgSo=; b=RbYghPy1Bm1owuo3tqM6J9zY62L1j8IiWImX4GJ4EsjlHQjZdCJwN/gkI+zkNr3Hx2 W4/cCQnVuTqPt34gfYrW0pL06I1m6GRYcMPhP7UON1hHHU2a9bvG4COfQDUZKzO6p5mY +PskVsjt1dgnXMqJIlywWm+8Glk/7oSAfQwOubTauDPQ+40YbQ2U0soX6ZEbMQyxp9qV xEK2yGpoX3fkYWhyje/72gifOtgQFyc0yO9sfW9KuizR6GD4EHikuUaf0wOq4K6qrfkV MLttVZSuigaNJ+pvvSzeUVpOEVguinyt+D8+Nxu+kpRluKR6V7h7USDAj+b9Dj/he1VH 1QGQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=4nRDXN5ZDY+7KKmxTUW+rmie0dxhoxA0kTC6dcBSgSo=; b=VH1T1zKZ6Y/uG+/uaRN9Q3JSqpOGszTBn/UKuuFq8T+v2Y9PKTajlm/qdtztQOAG7h WR01pwXixRGV6TlB4XpWSBsOxzFtj7BvD0K/ljLpC64j+tDq1y9+z8NenQmP6L4HajYP rJEkXlqD3rJl7q0mnLRcI2fDQmGiXt0kWWM8yEuCgcHkViQHbM1rvTOYgVkUe8ZeGKDB FK1gAp0UipFrkEMKzZbgAl1o2N3NSthTQ4p+lnwFDf4+rzS0ocuP6zZ8dJOmvRTojqcH tv6UyLIFAn476I7DM1HDNdfEs18tOs9V4EuMCsYpFk2/sGdp+Czy5yEwrZoMK+a+OAZT ylqg== X-Gm-Message-State: AOAM531YAVszP2oOPtFyWqMaEbmuad27sl3Oz4Vgu4pASDqjnu8L/aoo xX8hXhRPpj4dGDs6bmFJHEaDGA== X-Received: by 2002:a05:6638:102f:: with SMTP id n15mr9107540jan.28.1616704940793; Thu, 25 Mar 2021 13:42:20 -0700 (PDT) Received: from [192.168.1.30] ([65.144.74.34]) by smtp.gmail.com with ESMTPSA id j6sm2851060ila.31.2021.03.25.13.42.20 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 25 Mar 2021 13:42:20 -0700 (PDT) Subject: Re: [PATCH 0/2] Don't show PF_IO_WORKER in /proc//task/ To: "Eric W. Biederman" Cc: Linus Torvalds , io-uring , Linux Kernel Mailing List , Oleg Nesterov , Stefan Metzmacher References: <20210325164343.807498-1-axboe@kernel.dk> <3a1c02a5-db6d-e3e1-6ff5-69dd7cd61258@kernel.dk> From: Jens Axboe Message-ID: <27a54fc2-865a-d90b-2429-d91170be5873@kernel.dk> Date: Thu, 25 Mar 2021 14:42:19 -0600 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 3/25/21 2:21 PM, Eric W. Biederman wrote: > Jens Axboe writes: > >> On 3/25/21 1:42 PM, Linus Torvalds wrote: >>> On Thu, Mar 25, 2021 at 12:38 PM Linus Torvalds >>> wrote: >>>> >>>> I don't know what the gdb logic is, but maybe there's some other >>>> option that makes gdb not react to them? >>> >>> .. maybe we could have a different name for them under the task/ >>> subdirectory, for example (not just the pid)? Although that probably >>> messes up 'ps' too.. >> >> Heh, I can try, but my guess is that it would mess up _something_, if >> not ps/top. > > Hmm. > > So looking quickly the flip side of the coin is gdb (and other > debuggers) needs a way to know these threads are special, so it can know > not to attach. > > I suspect getting -EPERM (or possibly a different error code) when > attempting attach is the right was to know that a thread is not > available to be debugged. But that's what's being returned right now, and gdb seemingly doesn't really handle that. And even if it was just a gdb issue that could be fixed it (it definitely is), I'd still greatly prefer not having to do that. It just takes too long for packages to get updated in distros, and it'd be years until it got fixed widely. Secondly, I'm even more worried about cases that we haven't seen yet. I doubt that gdb is the only thing that'd fall over, not expecting threads in there that it cannot attach to. -- Jens Axboe