Module Name: src Committed By: ryo Date: Tue Mar 9 16:43:13 UTC 2021
Modified Files: src/sys/arch/aarch64/aarch64: db_machdep.c Log Message: "machine cpu" command shows pc of trapframe and the symbol To generate a diff of this commit: cvs rdiff -u -r1.35 -r1.36 src/sys/arch/aarch64/aarch64/db_machdep.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/arch/aarch64/aarch64/db_machdep.c diff -u src/sys/arch/aarch64/aarch64/db_machdep.c:1.35 src/sys/arch/aarch64/aarch64/db_machdep.c:1.36 --- src/sys/arch/aarch64/aarch64/db_machdep.c:1.35 Tue Mar 9 16:42:36 2021 +++ src/sys/arch/aarch64/aarch64/db_machdep.c Tue Mar 9 16:43:13 2021 @@ -1,4 +1,4 @@ -/* $NetBSD: db_machdep.c,v 1.35 2021/03/09 16:42:36 ryo Exp $ */ +/* $NetBSD: db_machdep.c,v 1.36 2021/03/09 16:43:13 ryo Exp $ */ /*- * Copyright (c) 2014 The NetBSD Foundation, Inc. @@ -30,7 +30,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: db_machdep.c,v 1.35 2021/03/09 16:42:36 ryo Exp $"); +__KERNEL_RCSID(0, "$NetBSD: db_machdep.c,v 1.36 2021/03/09 16:43:13 ryo Exp $"); #ifdef _KERNEL_OPT #include "opt_compat_netbsd32.h" @@ -944,11 +944,16 @@ db_md_switch_cpu_cmd(db_expr_t addr, boo if (!have_addr) { for (i = 0; i < ncpu; i++) { - if (db_readytoswitch[i] != NULL) - db_printf("cpu%d: ready. tf=%p\n", i, - db_readytoswitch[i]); - else + if (db_readytoswitch[i] != NULL) { + db_printf("cpu%d: ready. tf=%p, pc=%016lx ", i, + db_readytoswitch[i], + db_readytoswitch[i]->tf_pc); + db_printsym(db_readytoswitch[i]->tf_pc, + DB_STGY_ANY, db_printf); + db_printf("\n"); + } else { db_printf("cpu%d: not responding\n", i); + } } return; }