RFC ptp: vmclock: Add VM generation counter and ACPI notification
Get series with b4
b4 am [email protected]Versions newest first
- v1 RFC Latest2 patches 1 replyIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/2 | ptp: vmclock: add vm generation counterinclude/ | +19 | 1 reply | |
| 2/2 | ptp: vmclock: support device notificationsdrivers/ | +80 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.
Cover letter [RFC PATCH 0/2] ptp: vmclock: Add VM generation counter and ACPI notification
Similarly to live migration, starting a VM from some serialized state (aka snapshot) is an event which calls for adjusting guest clocks, hence a hypervisor should increase the disruption_marker before resuming the VM vCPUs, letting the guest know.
However, loading a snapshot, is slightly different than live migration, especially since we can start multiple VMs from the same serialized state. Apart from adjusting clocks, the guest needs to take additional action during such events, e.g. recreate UUIDs, reset network adapters/connections, reseed entropy pools, etc. These actions are not necessary during live migration. This calls for a differentiation between the two triggering events.
We differentiate between the two events via an extra field in the vmclock_abi, called vm_generation_counter. Whereas hypervisors should increase the disruption marker in both cases, they should only increase vm_generation_counter when a snapshot is loaded in a VM (not during live migration).
Additionally, we attach an ACPI notification to VMClock. Hypervisors should execute an ACPI notify operation every time seq_count changes to an even number. We implement the poll() interface for VMClock device. listeners of poll() will be notified about changes in the ABI every time the hypervisor sends us a notification.
Babis Chalios (2):
ptp: vmclock: add vm generation counter
ptp: vmclock: support device notifications
drivers/ptp/ptp_vmclock.c | 85 ++++++++++++++++++++++++++++++-- include/uapi/linux/vmclock-abi.h | 19 +++++++ 2 files changed, 99 insertions(+), 5 deletions(-)
Signature · 1 line
2.34.1