mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-08 02:03:56 -06:00
hpet: recover timer offset correctly
HPET saves its state by calculating the current time and recovers timer offset using this calculated value. But these calculations include divisions and multiplications. Therefore the timer state cannot be recovered precise enough. This patch introduces saving of the original value of the offset to preserve the determinism of the timer. Signed-off-by: Pavel Dovgalyuk <pavel.dovgaluk@ispras.ru> Signed-off-by: Maria Klimushenkova <maria.klimushenkova@ispras.ru> Reviewed-by: Juan Quintela <quintela@redhat.com> -- v3: Added compat property for correct migration. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
This commit is contained in:
parent
8cd91acec8
commit
829600a519
2 changed files with 33 additions and 3 deletions
|
@ -2,7 +2,11 @@
|
|||
#define HW_COMPAT_H
|
||||
|
||||
#define HW_COMPAT_2_11 \
|
||||
/* empty */
|
||||
{\
|
||||
.driver = "hpet",\
|
||||
.property = "hpet-offset-saved",\
|
||||
.value = "false",\
|
||||
},
|
||||
|
||||
#define HW_COMPAT_2_10 \
|
||||
{\
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue