From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id qisxE+TjvmqRzyUAWB0awg (envelope-from ) for ; Thu, 01 Oct 2026 18:51:16 -0400 Authentication-Results: simark.ca; dkim=pass (1024-bit key; unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=FHUkonhy; dkim-atps=neutral Received: by simark.ca (Postfix, from userid 112) id 3CE321E047; Thu, 01 Oct 2026 18:51:16 -0400 (EDT) X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-25) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-3.1 required=5.0 tests=ARC_SIGNED,ARC_VALID,BAYES_00, DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED,RCVD_IN_SBL_CSS autolearn=ham autolearn_force=no version=4.0.1 Received: from vm01.sourceware.org (vm01.sourceware.org [IPv6:2620:52:6:3111::32]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by simark.ca (Postfix) with ESMTPS id 64D461E047 for ; Thu, 01 Oct 2026 18:51:09 -0400 (EDT) Received: from vm01.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 62F194BB24EE for ; Thu, 1 Oct 2026 22:51:07 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 62F194BB24EE Authentication-Results: sourceware.org; dkim=pass (1024-bit key, unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=FHUkonhy Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by sourceware.org (Postfix) with ESMTP id 57F764BA2E1A for ; Thu, 1 Oct 2026 22:50:43 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 57F764BA2E1A Authentication-Results: sourceware.org; dmarc=pass (p=quarantine dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 57F764BA2E1A Authentication-Results: sourceware.org; arc=none smtp.remote-ip=170.10.133.124 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1790895043; cv=none; b=rEtmACh7PC7N5CrFxpgTkExNXv9f9T43iVUGTmjsiA2ahrF0+JkH3ow5xmW5TJMVoRPB7mhdkoCnMjjQAKmnvOmjieER9+mWPFb2zipVEHPiRWIx72CebUdWjF6FEKlQFAO24U4bMIrYhHGexJBL0VSUYos/rATr1jtfH9C7QIk= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1790895043; c=relaxed/simple; bh=+VI014qprIob4p0A1iSRWt9k0lb89iruDR1t6howv2A=; h=DKIM-Signature:Date:From:To:Subject:Message-ID:MIME-Version; b=TcCqeTSiIQEAfVmMjv24xQEYXLh9fMiZGJSKoPMUEEZasAK/zGkyBx4Sm9Vi41OjI1Lj9poCoPtTkpjO+KVguBWWMIwVtfQLfHCwJ3KjaAsPsiT0NWVLJkjipr506ZZCcKXbwmv/aiW23nEbvCIbk7m9hpBMmHoXEcc10M8N2y0= ARC-Authentication-Results: i=1; sourceware.org; dkim=pass (1024-bit key, unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=FHUkonhy DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 57F764BA2E1A DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1790895043; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=h/TEn1dzib+pP9zgDKl8dCcKuxDOkEX+fo8g1h2y0e4=; b=FHUkonhynW8NoHXn9uBVyTcuSG83yU/VkJO/ssdd9mJdewc7ERxxWYRI7hTzI4DFQv5pZ0 B97/lv9FYyfbOEdNvUUcbQOC+d9MlMiwSIKSzB2vWXB0AlpqyQmm8iD3xv0OYhdnHx1504 xfbOzk5PClG3UH9N7V2+ix4cqvTZhTg= Received: from mx-prod-mc-03.mail-002.prod.us-west-2.aws.redhat.com (ec2-54-186-198-63.us-west-2.compute.amazonaws.com [54.186.198.63]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-160-OP_mxUBoM9GtIkApwSpwhg-1; Thu, 01 Oct 2026 18:50:36 -0400 X-MC-Unique: OP_mxUBoM9GtIkApwSpwhg-1 X-Mimecast-MFC-AGG-ID: OP_mxUBoM9GtIkApwSpwhg_1790895035 Received: from mx-prod-int-05.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-05.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.17]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx-prod-mc-03.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id B59151955BFC; Thu, 1 Oct 2026 22:50:34 +0000 (UTC) Received: from f44-mesa-1 (unknown [10.22.80.12]) by mx-prod-int-05.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id 8BDCE1956095; Thu, 1 Oct 2026 22:50:32 +0000 (UTC) Date: Thu, 1 Oct 2026 15:50:29 -0700 From: Kevin Buettner To: Alexandra Petlanova Hajkova Cc: gdb-patches@sourceware.org, Tom Tromey , Tom de Vries , Andrew Burgess , Pedro Alves Subject: Re: [RFC PATCH v2] gdb: Add drgn-why-sleeping command Message-ID: <20261001154858.0995879d@f44-mesa-1> In-Reply-To: References: <20260929190349.312877-1-ahajkova@redhat.com> <20260930204013.717302f1@f44-mesa-1> Organization: Red Hat MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.0 on 10.30.177.17 X-Mimecast-Spam-Score: 0 X-Mimecast-MFC-PROC-ID: kpyMbNdfF0c7vKV7-NB28nLafYjpRjo002owDAv3RKA_1790895035 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gdb-patches-bounces~public-inbox=simark.ca@sourceware.org On Thu, 1 Oct 2026 11:01:19 +0200 Alexandra Petlanova Hajkova wrote: > > Summary: this is a useful idea, and v2 fixes the concrete v1 > > problems. Before v3, I'd like to see the "does this belong in > > GDB" question settled with the maintainers. On the code side, I'd > > most like to see M1 (PID namespace), M2 (partial debuginfo), M3 > > (unhandled drgn exceptions) and the drgn.internal / sys.executable > > dependency (M4) fixed. > > thank you very much for the insightful review. I'd love to get more > feedback > on "does this belong in GDB" question. [earlier reples trimmed somewhat] I've given it some more thought. I don't think we should introduce a drgn-why-sleeping facility into GDB as a "first class citizen", i.e. something which is part of GDB that gets regular testing. The requirements / dependencies are onerous: 1. You must have drgn installed; this part is the easiest since it's just a 'pip install'. 2. kernel debuginfo - this is pretty big. When I had it tested on Fedora 44, it was a 1.3 GiB download and it takes 5.5 GiB on disk. Moreover, the debuginfo must match the currently running kernel. New debuginfo would need to be updated every time that the kernel is updated. 3. Read access to /proc/kcore is required. Drgn's sudo helper passes the descriptor back to GDB so that GDB itself stays unprivileged, but the descriptor conveys read access to the whole of kernel memory - the same access root would have. Care should, therefore, be taken on production systems where kernel-memory secrets must not be disclosed. 4. Secure Boot plus lockdown=confidentiality prevents it from working. (My AI tells me that Secure Boot enabled with lockdown set to 'integrity' will work, but this is not something I've tested.) If we had some sort of user-facing contrib directory, it could be placed there. Alternately, as the AI reviewer suggested, it could go into a contrib directory in the drgn package. Kevin