From patchwork Mon Aug 2 05:41:10 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jordan Niethe X-Patchwork-Id: 1512296 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.ozlabs.org (client-ip=112.213.38.117; helo=lists.ozlabs.org; envelope-from=pdbg-bounces+incoming=patchwork.ozlabs.org@lists.ozlabs.org; receiver=) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20161025 header.b=aiBIn2VR; dkim-atps=neutral Received: from lists.ozlabs.org (lists.ozlabs.org [112.213.38.117]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4GdTLr5gQSz9sfG for ; Mon, 2 Aug 2021 16:56:36 +1000 (AEST) Received: from boromir.ozlabs.org (localhost [IPv6:::1]) by lists.ozlabs.org (Postfix) with ESMTP id 4GdTLr4d9Gz308t for ; Mon, 2 Aug 2021 16:56:36 +1000 (AEST) Authentication-Results: lists.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20161025 header.b=aiBIn2VR; dkim-atps=neutral X-Original-To: pdbg@lists.ozlabs.org Delivered-To: pdbg@lists.ozlabs.org Authentication-Results: lists.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=gmail.com (client-ip=2607:f8b0:4864:20::102f; helo=mail-pj1-x102f.google.com; envelope-from=jniethe5@gmail.com; receiver=) Authentication-Results: lists.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20161025 header.b=aiBIn2VR; dkim-atps=neutral Received: from mail-pj1-x102f.google.com (mail-pj1-x102f.google.com [IPv6:2607:f8b0:4864:20::102f]) (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 lists.ozlabs.org (Postfix) with ESMTPS id 4GdRhY6QCYz3022 for ; Mon, 2 Aug 2021 15:41:49 +1000 (AEST) Received: by mail-pj1-x102f.google.com with SMTP id o44-20020a17090a0a2fb0290176ca3e5a2fso23137760pjo.1 for ; Sun, 01 Aug 2021 22:41:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=B6+K/wWcQ98QT35LNxhOd1ZaRzyCLW3hczTnMXZrkRE=; b=aiBIn2VRBnr+VLkpdVRvuO84oJvIcLNjG9/n7zIGGitZnsBKkG0H6QrQ4rWf0QuK7w HIPlcziJJXTsGY4IVA3ikK6z2d4BOmx511nJ6o61uMqKxhWlRyErTDIovynToNfXXZos LWjs5ACZ41Hv0RqVLWQmQuubREGBh9zW6FwfzMafUp6oQ1dTXO7fHI5o3H11O+ZQecpT rI+2oxvTyLMjQrkdMUbHvV25+BrjdXLPvq/mW0ddIsBDbwswsBZXCObmVnG0QjfCifKe Hf6v0VT3OhOKRHC/nXux7/8zW6YLNPT6HRj0Tgwkz2baq/GASFaVStM6r3g0x140e2RM J16Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=B6+K/wWcQ98QT35LNxhOd1ZaRzyCLW3hczTnMXZrkRE=; b=POd3OQxfiuT5RW5+Bjqc6swbqCb+zU5PWyJafLGg35dTh33jzVtRphxRN3VbepPcpF DCPYC2nQNgoE81JIkeeGcSYyAwuQQr0IHNvRoPfxwShxx4F2EwSp/N+eu/Oarwq4GAIE vDJSX8KsszgwDdNAuIEv+UhDNfrJfa8w4BO/CmJhCr9VyjhGwJZXzgL55kHRXo7fSe2e CJdSFRklTGWcjyYWAsUa1g8c72af6BKkK0wpKigZVGjht5K8KS+zDQadxDpNfenXacsZ L9V+e6n5WSFo6uvS5+sjovsdJD31OZbSuWaJ0k/YiV9nBJlkuLJ5/TnmQleXGvHm68Si 1D6w== X-Gm-Message-State: AOAM5324ikPYl9rKeU/dVUv+JwEaaGIvITBkevwwnksZHWwkWSr1om2X 5AoEHJYVpBUjEpJ26+sow4iEEzR++/s= X-Google-Smtp-Source: ABdhPJwie3aW5y72iZvZyZ1flEA0BqI+Cl0476Db/kzY+k32Iq2eeLmgmdePLKYryoDlKaNwnFGX4Q== X-Received: by 2002:a05:6a00:2b5:b029:3bc:3183:c370 with SMTP id q21-20020a056a0002b5b02903bc3183c370mr4293888pfs.68.1627882907202; Sun, 01 Aug 2021 22:41:47 -0700 (PDT) Received: from tee480.ozlabs.ibm.com (159-196-117-139.9fc475.syd.nbn.aussiebb.net. [159.196.117.139]) by smtp.gmail.com with ESMTPSA id 189sm1741852pfx.135.2021.08.01.22.41.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 01 Aug 2021 22:41:46 -0700 (PDT) From: Jordan Niethe To: pdbg@lists.ozlabs.org Date: Mon, 2 Aug 2021 15:41:10 +1000 Message-Id: <20210802054112.461728-11-jniethe5@gmail.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20210802054112.461728-1-jniethe5@gmail.com> References: <20210802054112.461728-1-jniethe5@gmail.com> MIME-Version: 1.0 X-Mailman-Approved-At: Mon, 02 Aug 2021 16:56:28 +1000 Subject: [Pdbg] [PATCH 10/12] htm: Check threads !active instead of quiesced X-BeenThere: pdbg@lists.ozlabs.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "mailing list for https://github.com/open-power/pdbg development" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Jordan Niethe Errors-To: pdbg-bounces+incoming=patchwork.ozlabs.org@lists.ozlabs.org Sender: "Pdbg" The P10 thread_state quiesced status is maint_mode && thread_quiesced && ict_empty which is more than is needed for taking a core HTM trace. Instead check the secondary threads are !active. Signed-off-by: Jordan Niethe --- src/htm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/htm.c b/src/htm.c index a08f244b2a3c..ba1175e110f3 100644 --- a/src/htm.c +++ b/src/htm.c @@ -230,7 +230,7 @@ static bool is_smt1(struct pdbg_target *target) } /* secondary thread */ - if (thread_status(target).quiesced) + if (!thread_status(target).active) return true; fail: