qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH 8/8] ppc/ppc405: Dump specific registers


From: Richard Henderson
Subject: Re: [PATCH 8/8] ppc/ppc405: Dump specific registers
Date: Thu, 23 Dec 2021 13:47:46 -0800
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.14.0

On 12/21/21 10:40 PM, Cédric Le Goater wrote:
Signed-off-by: Cédric Le Goater <clg@kaod.org>
---
  target/ppc/cpu_init.c | 11 +++++++++++
  1 file changed, 11 insertions(+)

diff --git a/target/ppc/cpu_init.c b/target/ppc/cpu_init.c
index 9ef9a1a5ddd5..8f6a58e82483 100644
--- a/target/ppc/cpu_init.c
+++ b/target/ppc/cpu_init.c
@@ -8689,6 +8689,17 @@ void ppc_cpu_dump_state(CPUState *cs, FILE *f, int flags)
           * they can be read with "p $ivor0", "p $ivor1", etc.
           */
      }
+    if (env->excp_model == POWERPC_EXCP_40x) {

Perhaps turn this and the previous booke test into a switch.

Otherwise,
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>

r~

+        qemu_fprintf(f, "  TCR " TARGET_FMT_lx "   TSR " TARGET_FMT_lx
+                     "    ESR " TARGET_FMT_lx "   DEAR " TARGET_FMT_lx "\n",
+                     env->spr[SPR_40x_TCR], env->spr[SPR_40x_TSR],
+                     env->spr[SPR_40x_ESR], env->spr[SPR_40x_DEAR]);
+
+        qemu_fprintf(f, " EVPR " TARGET_FMT_lx "  SRR2 " TARGET_FMT_lx
+                     "   SRR3 " TARGET_FMT_lx  "   PID " TARGET_FMT_lx "\n",
+                     env->spr[SPR_40x_EVPR], env->spr[SPR_40x_SRR2],
+                     env->spr[SPR_40x_SRR3], env->spr[SPR_40x_PID]);
+    }
#if defined(TARGET_PPC64)
      if (env->flags & POWERPC_FLAG_CFAR) {





reply via email to

[Prev in Thread] Current Thread [Next in Thread]