]> git.proxmox.com Git - mirror_qemu.git/commit
target/ppc: Migrate DECR SPR
authorNicholas Piggin <npiggin@gmail.com>
Tue, 8 Aug 2023 04:19:52 +0000 (14:19 +1000)
committerCédric Le Goater <clg@kaod.org>
Wed, 6 Sep 2023 09:19:33 +0000 (11:19 +0200)
commit578912ad7312ececb9a88b4c38d406dda640346d
treef08269af71a20f92513f771879c312fa08f8ffea
parentfebb71d543a8f747b2f8aaf0182d0a385c6a02c3
target/ppc: Migrate DECR SPR

TCG does not maintain the DEC reigster in the SPR array, so it does get
migrated. TCG also needs to re-start the decrementer timer on the
destination machine.

Load and store the decrementer into the SPR when migrating. This works
for the level-triggered (book3s) decrementer, and should be compatible
with existing KVM machines that do keep the DEC value there.

This fixes lost decrementer interrupt on migration that can cause
hangs, as well as other problems including record-replay bugs.

Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
Signed-off-by: Cédric Le Goater <clg@kaod.org>
target/ppc/machine.c