aboutsummaryrefslogtreecommitdiff
path: root/target/i386/cpu.c
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2022-10-13 18:19:26 +0100
committerPaolo Bonzini <pbonzini@redhat.com>2022-10-18 13:58:04 +0200
commit08c4f4db60f8744e7aec107b056ea1a9d6d20265 (patch)
tree4d0345ac90dae868da36464c8c69197d7eabeb3d /target/i386/cpu.c
parent33ab5f24913db8d5590fe4155829bd38e7902506 (diff)
downloadqemu-08c4f4db60f8744e7aec107b056ea1a9d6d20265.zip
qemu-08c4f4db60f8744e7aec107b056ea1a9d6d20265.tar.gz
qemu-08c4f4db60f8744e7aec107b056ea1a9d6d20265.tar.bz2
target/i386: Use device_cold_reset() to reset the APIC
The semantic difference between the deprecated device_legacy_reset() function and the newer device_cold_reset() function is that the new function resets both the device itself and any qbuses it owns, whereas the legacy function resets just the device itself and nothing else. The x86_cpu_after_reset() function uses device_legacy_reset() to reset the APIC; this is an APICCommonState and does not have any qbuses, so for this purpose the two functions behave identically and we can stop using the deprecated one. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Acked-by: Michael S. Tsirkin <mst@redhat.com> Message-Id: <20221013171926.1447899-1-peter.maydell@linaro.org> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'target/i386/cpu.c')
-rw-r--r--target/i386/cpu.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/target/i386/cpu.c b/target/i386/cpu.c
index 90aec2f..6279745 100644
--- a/target/i386/cpu.c
+++ b/target/i386/cpu.c
@@ -6043,7 +6043,7 @@ void x86_cpu_after_reset(X86CPU *cpu)
}
if (cpu->apic_state) {
- device_legacy_reset(cpu->apic_state);
+ device_cold_reset(cpu->apic_state);
}
#endif
}