aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2022-12-19 10:28:57 +0000
committerPeter Maydell <peter.maydell@linaro.org>2022-12-19 10:28:57 +0000
commitc15dc499cc22f4a71639e42e36051e118761c25f (patch)
tree580f2f48bbcf56c8ab7062c76220e4697b5eac21
parent4f9a4cd37eb2f0c4e6be83640fcc5c31d4bf99e3 (diff)
parent3b1371159cdb6f31d87fbb339853cc6a963ea6a1 (diff)
Merge tag 'pull-misc-20221218' of https://gitlab.com/rth7680/qemu into staging
Fix tricore gdbstub. Fix superh_cpu_synchronize_from_tb. # gpg: Signature made Sun 18 Dec 2022 17:48:54 GMT # gpg: using RSA key 7A481E78868B4DB6A85A05C064DF38E8AF7E215F # gpg: issuer "richard.henderson@linaro.org" # gpg: Good signature from "Richard Henderson <richard.henderson@linaro.org>" [full] # Primary key fingerprint: 7A48 1E78 868B 4DB6 A85A 05C0 64DF 38E8 AF7E 215F * tag 'pull-misc-20221218' of https://gitlab.com/rth7680/qemu: target/tricore: Fix gdbstub write to address registers target/sh4: Mask restore of env->flags from tb->flags Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
-rw-r--r--target/sh4/cpu.c2
-rw-r--r--target/tricore/gdbstub.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/target/sh4/cpu.c b/target/sh4/cpu.c
index 951eb6b9c8..f0934b20fa 100644
--- a/target/sh4/cpu.c
+++ b/target/sh4/cpu.c
@@ -47,7 +47,7 @@ static void superh_cpu_synchronize_from_tb(CPUState *cs,
SuperHCPU *cpu = SUPERH_CPU(cs);
cpu->env.pc = tb_pc(tb);
- cpu->env.flags = tb->flags;
+ cpu->env.flags = tb->flags & TB_FLAG_ENVFLAGS_MASK;
}
static void superh_restore_state_to_opc(CPUState *cs,
diff --git a/target/tricore/gdbstub.c b/target/tricore/gdbstub.c
index ebf32defde..3a27a7e65d 100644
--- a/target/tricore/gdbstub.c
+++ b/target/tricore/gdbstub.c
@@ -130,7 +130,7 @@ int tricore_cpu_gdb_write_register(CPUState *cs, uint8_t *mem_buf, int n)
if (n < 16) { /* data registers */
env->gpr_d[n] = tmp;
} else if (n < 32) { /* address registers */
- env->gpr_d[n - 16] = tmp;
+ env->gpr_a[n - 16] = tmp;
} else {
tricore_cpu_gdb_write_csfr(env, n, tmp);
}