Skip to content

Commit

Permalink
target/arm: Set TCGCPUOps.restore_state_to_opc for v7m
Browse files Browse the repository at this point in the history
This setting got missed, breaking v7m.

Fixes: 56c6c98 ("target/arm: Convert to tcg_ops restore_state_to_opc")
Resolves: https://gitlab.com/qemu-project/qemu/-/issues/1347
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Evgeny Ermakov <evgeny.v.ermakov@gmail.com>
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Message-Id: <20221129204146.550394-1-richard.henderson@linaro.org>
  • Loading branch information
unspecd authored and stefanhaRH committed Nov 29, 2022
1 parent 7103895 commit 475e56b
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 3 deletions.
6 changes: 3 additions & 3 deletions target/arm/cpu.c
Original file line number Diff line number Diff line change
Expand Up @@ -91,9 +91,9 @@ void arm_cpu_synchronize_from_tb(CPUState *cs,
}
}

static void arm_restore_state_to_opc(CPUState *cs,
const TranslationBlock *tb,
const uint64_t *data)
void arm_restore_state_to_opc(CPUState *cs,
const TranslationBlock *tb,
const uint64_t *data)
{
CPUARMState *env = cs->env_ptr;

Expand Down
1 change: 1 addition & 0 deletions target/arm/cpu_tcg.c
Original file line number Diff line number Diff line change
Expand Up @@ -1035,6 +1035,7 @@ static const struct TCGCPUOps arm_v7m_tcg_ops = {
.initialize = arm_translate_init,
.synchronize_from_tb = arm_cpu_synchronize_from_tb,
.debug_excp_handler = arm_debug_excp_handler,
.restore_state_to_opc = arm_restore_state_to_opc,

#ifdef CONFIG_USER_ONLY
.record_sigsegv = arm_cpu_record_sigsegv,
Expand Down
4 changes: 4 additions & 0 deletions target/arm/internals.h
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,10 @@ static inline int r14_bank_number(int mode)
void arm_cpu_register_gdb_regs_for_features(ARMCPU *cpu);
void arm_translate_init(void);

void arm_restore_state_to_opc(CPUState *cs,
const TranslationBlock *tb,
const uint64_t *data);

#ifdef CONFIG_TCG
void arm_cpu_synchronize_from_tb(CPUState *cs, const TranslationBlock *tb);
#endif /* CONFIG_TCG */
Expand Down

0 comments on commit 475e56b

Please sign in to comment.