From nobody Thu Aug 11 14:32:46 2022 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4M3Tmb3VPkz4Y1xV; Thu, 11 Aug 2022 14:32:47 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4M3Tmb0cnlz3MRV; Thu, 11 Aug 2022 14:32:47 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1660228367; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Bz0kh5ly7CTrwHc3BmVb00Xn/NuujQS1lMSGAHRLIcU=; b=QGC8jPzlIYyuncjvIqLMTwCVsm0G6I+dxr3D4bnjpd+C6nVtLqxyfXMWlUPrWZwrn8WU1k XObdiINp9fvsil7gLRNKZzqOykkfl2IaQwcIWWaUgvf0qgSRvrB+VPVo7XIkhHWyWVF7Sn o6CHvOSy9w1QLtd66MI1I4mN8T8a3ZHTDLnISEbdVtcc+87MYG+IiDskCst6i4OfyU9G1c 152Husd2N8bLFSrbXTRq6NYedCawdhs+BAxav30k4UJROMlDZl6BopAH+ZtUIcLEMclfKs rcGo2jnP5QYWuswOtAFFx1StHIyVKReB9vOW16Pz43EQVR5/PabHeJMLE6ELDQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4M3TmZ6bzHzvGK; Thu, 11 Aug 2022 14:32:46 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 27BEWk8f004496; Thu, 11 Aug 2022 14:32:46 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 27BEWkaI004495; Thu, 11 Aug 2022 14:32:46 GMT (envelope-from git) Date: Thu, 11 Aug 2022 14:32:46 GMT Message-Id: <202208111432.27BEWkaI004495@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mitchell Horne Subject: git: 760fb765b5bb - stable/13 - riscv: implement db_show_mdpcpu() List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 760fb765b5bb75d68f0455e408ec79a0e328d8de Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1660228367; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Bz0kh5ly7CTrwHc3BmVb00Xn/NuujQS1lMSGAHRLIcU=; b=Ol1rB+BJbuKKdtl/3FK4k3cw8sBrBFDJlHt8pSx6vwSO1An9apIk2LulIs9tNl/YuupqB7 U0pqYp09UfRxhjTc+4cWdq6VNCgtpda92EsCZtQ1G2u06VUZkXmsQL56Z3POf5QpcvTx2o Kj8X3snTJb5ijWYnb5mMDqDta95U+lE3W+O04DIqPO2jEKBkPLEXE4RCMe0cbSI3jqX1uq 6PxRMC3xbPY7g2lT49bCKF/OzlqruPzv58yZbvjIQykiNIKlA/XwMbkYU6yLPx+uc5uCf2 W6ozgA2nn7YtBTGbV3jK45e2SuKD9tiKwGBsZkTPyNVHiyfMPyapCMz/QNsyGQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1660228367; a=rsa-sha256; cv=none; b=UBnPEgDt1oexdprviuLfP2gfsREV/yRV5zG3UGXjPJvafEnUVZ6sPqbTp8fA14Zcx5v1zV DwIP3NMoNdfEGBWuoXkmh3QbkVWNSW3idt/IGgoHWC48uNpBKajpYQUFlSLWovu6hFveNy b38SmGiVwAfmuOTMC/dRkzNlYvc7TKOESOyDxRhDRJ3THQ8Mck8LW3QppsJIrybZ2c7V/l Yk5pkDQTv5LuBdWc5OZEkB7/iFWVT/WBnfssVDRiCTWsoXCG3IX+6BroJP44/nXNWPyonI QoHoKqzrtfcZU1ErfJe4Yt77PfDmxN2KEmUGhBiXeMljq31STMsguo30nop1BQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch stable/13 has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=760fb765b5bb75d68f0455e408ec79a0e328d8de commit 760fb765b5bb75d68f0455e408ec79a0e328d8de Author: Mitchell Horne AuthorDate: 2021-10-04 20:47:49 +0000 Commit: Mitchell Horne CommitDate: 2022-08-11 14:21:41 +0000 riscv: implement db_show_mdpcpu() This prints the machine-dependent members of struct pcpu when executing the 'show pcpu' or 'show all pcpu' ddb(4) commands. MFC after: 3 days (cherry picked from commit 4fffc56c6e4c97aa76b31060e806ccdafb1afacd) --- sys/riscv/include/pcpu.h | 1 + sys/riscv/riscv/db_interface.c | 3 +++ 2 files changed, 4 insertions(+) diff --git a/sys/riscv/include/pcpu.h b/sys/riscv/include/pcpu.h index 5068596462fc..bdb2a4e2c5df 100644 --- a/sys/riscv/include/pcpu.h +++ b/sys/riscv/include/pcpu.h @@ -44,6 +44,7 @@ #define ALT_STACK_SIZE 128 +/* Keep in sync with db_show_mdpcpu() */ #define PCPU_MD_FIELDS \ struct pmap *pc_curpmap; /* Currently active pmap */ \ uint32_t pc_pending_ipis; /* IPIs pending to this CPU */ \ diff --git a/sys/riscv/riscv/db_interface.c b/sys/riscv/riscv/db_interface.c index 291fd2c2d8fa..5c959792d368 100644 --- a/sys/riscv/riscv/db_interface.c +++ b/sys/riscv/riscv/db_interface.c @@ -106,6 +106,9 @@ struct db_variable *db_eregs = db_regs + nitems(db_regs); void db_show_mdpcpu(struct pcpu *pc) { + db_printf("curpmap = %p\n", pc->pc_curpmap); + db_printf("pending_ipis = %x\n", pc->pc_pending_ipis); + db_printf("hart = %u\n", pc->pc_hart); } /*