diff options
| author | Philippe Mathieu-Daudé <philmd@linaro.org> | 2023-09-15 22:55:45 +0200 |
|---|---|---|
| committer | Philippe Mathieu-Daudé <philmd@linaro.org> | 2023-11-07 12:13:27 +0100 |
| commit | bb6cf6f0168efadb95cf3e41963ec295ad28a941 (patch) | |
| tree | ce4c36ff9afead66aea9f6f2949736dadb04e4c9 /accel/tcg/tcg-accel-ops.c | |
| parent | 1b5120d74b1e19c12f8f476f8015a0ac87e11878 (diff) | |
| download | focaccia-qemu-bb6cf6f0168efadb95cf3e41963ec295ad28a941.tar.gz focaccia-qemu-bb6cf6f0168efadb95cf3e41963ec295ad28a941.zip | |
accel/tcg: Factor tcg_cpu_reset_hold() out
Factor the TCG specific code from cpu_common_reset_hold() to tcg_cpu_reset_hold() within tcg-accel-ops.c. Since this file is sysemu specific, we can inline tcg_flush_softmmu_tlb(), removing its declaration in "exec/cpu-common.h". Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org> Reviewed-by: Anton Johansson <anjo@rev.ng> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Message-Id: <20230918104153.24433-4-philmd@linaro.org>
Diffstat (limited to 'accel/tcg/tcg-accel-ops.c')
| -rw-r--r-- | accel/tcg/tcg-accel-ops.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/accel/tcg/tcg-accel-ops.c b/accel/tcg/tcg-accel-ops.c index 7ddb05c332..1b57290682 100644 --- a/accel/tcg/tcg-accel-ops.c +++ b/accel/tcg/tcg-accel-ops.c @@ -78,6 +78,13 @@ int tcg_cpus_exec(CPUState *cpu) return ret; } +static void tcg_cpu_reset_hold(CPUState *cpu) +{ + tcg_flush_jmp_cache(cpu); + + tlb_flush(cpu); +} + /* mask must never be zero, except for A20 change call */ void tcg_handle_interrupt(CPUState *cpu, int mask) { @@ -206,6 +213,7 @@ static void tcg_accel_ops_init(AccelOpsClass *ops) } } + ops->cpu_reset_hold = tcg_cpu_reset_hold; ops->supports_guest_debug = tcg_supports_guest_debug; ops->insert_breakpoint = tcg_insert_breakpoint; ops->remove_breakpoint = tcg_remove_breakpoint; |