[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 11/31] plugins: Check if vCPU is realized
From: |
Alex Bennée |
Subject: |
[PATCH 11/31] plugins: Check if vCPU is realized |
Date: |
Mon, 25 Sep 2023 15:48:34 +0100 |
From: Akihiko Odaki <akihiko.odaki@daynix.com>
The created member of CPUState tells if the vCPU thread is started, and
will be always false for the user space emulation that manages threads
independently. Use the realized member of DeviceState, which is valid
for both of the system and user space emulation.
Fixes: 54cb65d858 ("plugin: add core code")
Signed-off-by: Akihiko Odaki <akihiko.odaki@daynix.com>
Message-Id: <20230912224107.29669-4-akihiko.odaki@daynix.com>
Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
---
plugins/core.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/plugins/core.c b/plugins/core.c
index 3c4e26c7ed..fcd33a2bff 100644
--- a/plugins/core.c
+++ b/plugins/core.c
@@ -64,7 +64,7 @@ static void plugin_cpu_update__locked(gpointer k, gpointer v,
gpointer udata)
CPUState *cpu = container_of(k, CPUState, cpu_index);
run_on_cpu_data mask = RUN_ON_CPU_HOST_ULONG(*plugin.mask);
- if (cpu->created) {
+ if (DEVICE(cpu)->realized) {
async_run_on_cpu(cpu, plugin_cpu_update__async, mask);
} else {
plugin_cpu_update__async(cpu, mask);
--
2.39.2
- [PATCH 04/31] docs: mark CRIS support as deprecated, (continued)
- [PATCH 13/31] gdbstub: Introduce GDBFeature structure, Alex Bennée, 2023/09/25
- [PATCH 14/31] target/arm: Move the reference to arm-core.xml, Alex Bennée, 2023/09/25
- [PATCH 10/31] gdbstub: Fix target.xml response, Alex Bennée, 2023/09/25
- [PATCH 15/31] hw/core/cpu: Return static value with gdb_arch_name(), Alex Bennée, 2023/09/25
- [PATCH 23/31] plugins: Set final instruction count in plugin_gen_tb_end, Alex Bennée, 2023/09/25
- [PATCH 11/31] plugins: Check if vCPU is realized,
Alex Bennée <=
- [PATCH 19/31] gdbstub: Remove gdb_has_xml variable, Alex Bennée, 2023/09/25
- [PATCH 21/31] accel/tcg: Add plugin_enabled to DisasContextBase, Alex Bennée, 2023/09/25
- [RFC PATCH 27/31] sysemu: add set_virtual_time to accel ops, Alex Bennée, 2023/09/25
- [PATCH 25/31] contrib/plugins: fix coverity warning in lockstep, Alex Bennée, 2023/09/25
- [RFC PATCH 31/31] contrib/plugins: add iops plugin example for cost modelling, Alex Bennée, 2023/09/25
- [PATCH 22/31] target/sh4: Disable decode_gusa when plugins enabled, Alex Bennée, 2023/09/25
- [PATCH 18/31] target/ppc: Remove references to gdb_has_xml, Alex Bennée, 2023/09/25
- [PATCH 16/31] gdbstub: Use g_markup_printf_escaped(), Alex Bennée, 2023/09/25
- [RFC PATCH 29/31] sysemu: generalise qtest_warp_clock as qemu_clock_advance_virtual_time, Alex Bennée, 2023/09/25
- [PATCH 24/31] contrib/plugins: fix coverity warning in cache, Alex Bennée, 2023/09/25