All of lore.kernel.org
 help / color / mirror / Atom feed
* [RFC PATCH v3 0/5] x86/kvm: Virtual suspend time injection support
@ 2021-10-20 12:04 ` Hikaru Nishida
  0 siblings, 0 replies; 30+ messages in thread
From: Hikaru Nishida @ 2021-10-20 12:04 UTC (permalink / raw)
  To: linux-kernel, dme, tglx, mlevitsk, linux, pbonzini, vkuznets, maz, will
  Cc: suleiman, senozhatsky, kvmarm, linux-arm-kernel, Hikaru Nishida,
	Andy Lutomirski, Arnd Bergmann, Borislav Petkov, Dave Hansen,
	Geert Uytterhoeven, H. Peter Anvin, Ingo Molnar, Ingo Molnar,
	Jim Mattson, Joerg Roedel, John Stultz, Jonathan Corbet,
	Juergen Gross, Kees Cook, Lai Jiangshan, Linus Walleij,
	Peter Zijlstra, Sean Christopherson, Stephen Boyd, Wanpeng Li,
	kvm, linux-doc, x86


Hi,

This patch series adds virtual suspend time injection support to KVM.
It is an updated version of the following series:
v2:
https://lore.kernel.org/kvm/20210806100710.2425336-1-hikalium@chromium.org/
v1:
https://lore.kernel.org/kvm/20210426090644.2218834-1-hikalium@chromium.org/

Please take a look again.

To kvm/arm64 folks:
I'm going to implement this mechanism to ARM64 as well but not
sure which function should be used to make an IRQ (like kvm_apic_set_irq
in x86) and if it is okay to use kvm_gfn_to_hva_cache /
kvm_write_guest_cached for sharing the suspend duration.
Please let me know if there is other suitable way or any suggestions.

Thanks,

Hikaru Nishida


Changes in v3:
- Used PM notifier instead of modifying timekeeping_resume()
  - This avoids holding kvm_lock under interrupt disabled context.
- Used KVM_REQ_* to make a request for vcpus.
- Reused HYPERVISOR_CALLBACK_VECTOR IRQ instead of adding a new one.
- Extracted arch-independent parts.
- Fixed other reviewed points.

Hikaru Nishida (5):
  timekeeping: Expose tk->offs_boot via ktime_get_offs_boot_ns
  kvm/x86: Include asm/pvclock.h in asm/kvmclock.h
  kvm/x86: virtual suspend time injection: Add common definitions
  kvm/x86: virtual suspend time injection: Implement host side
  kvm/x86: virtual suspend time injection: Implement guest side

 Documentation/virt/kvm/cpuid.rst     |   3 +
 Documentation/virt/kvm/msr.rst       |  30 ++++++++
 arch/x86/Kconfig                     |  13 ++++
 arch/x86/include/asm/idtentry.h      |   2 +-
 arch/x86/include/asm/kvm_host.h      |   2 +
 arch/x86/include/asm/kvmclock.h      |  11 +++
 arch/x86/include/uapi/asm/kvm_para.h |   6 ++
 arch/x86/kernel/kvm.c                |  14 +++-
 arch/x86/kernel/kvmclock.c           |  26 +++++++
 arch/x86/kvm/Kconfig                 |  13 ++++
 arch/x86/kvm/cpuid.c                 |   4 +
 arch/x86/kvm/x86.c                   | 109 +++++++++++++++++++++++++++
 arch/x86/mm/fault.c                  |   2 +-
 include/linux/kvm_host.h             |  48 ++++++++++++
 include/linux/timekeeper_internal.h  |   5 ++
 include/linux/timekeeping.h          |   6 ++
 kernel/time/timekeeping.c            |  56 ++++++++++++++
 virt/kvm/kvm_main.c                  |  88 +++++++++++++++++++++
 18 files changed, 432 insertions(+), 6 deletions(-)

-- 
2.33.0.1079.g6e70778dc9-goog


^ permalink raw reply	[flat|nested] 30+ messages in thread

end of thread, other threads:[~2022-04-06 15:21 UTC | newest]

Thread overview: 30+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-10-20 12:04 [RFC PATCH v3 0/5] x86/kvm: Virtual suspend time injection support Hikaru Nishida
2021-10-20 12:04 ` Hikaru Nishida
2021-10-20 12:04 ` Hikaru Nishida
2021-10-20 12:04 ` [RFC PATCH v3 1/5] timekeeping: Expose tk->offs_boot via ktime_get_offs_boot_ns Hikaru Nishida
2021-10-20 12:04   ` Hikaru Nishida
2021-10-20 12:04   ` Hikaru Nishida
2021-10-20 12:04 ` [RFC PATCH v3 2/5] kvm/x86: Include asm/pvclock.h in asm/kvmclock.h Hikaru Nishida
2021-10-20 12:04   ` Hikaru Nishida
2021-10-20 12:04   ` Hikaru Nishida
2021-10-20 12:04 ` [RFC PATCH v3 3/5] kvm/x86: virtual suspend time injection: Add common definitions Hikaru Nishida
2021-10-20 12:04   ` Hikaru Nishida
2021-10-20 12:04   ` Hikaru Nishida
2021-10-20 12:04 ` [RFC PATCH v3 4/5] kvm/x86: virtual suspend time injection: Implement host side Hikaru Nishida
2021-10-20 12:04   ` Hikaru Nishida
2021-10-20 12:04   ` Hikaru Nishida
2021-10-20 12:04 ` [RFC PATCH v3 5/5] kvm/x86: virtual suspend time injection: Implement guest side Hikaru Nishida
2021-10-20 12:04   ` Hikaru Nishida
2021-10-20 12:04   ` Hikaru Nishida
2021-10-20 13:52 ` [RFC PATCH v3 0/5] x86/kvm: Virtual suspend time injection support Marc Zyngier
2021-10-20 13:52   ` Marc Zyngier
2021-10-20 13:52   ` Marc Zyngier
2021-11-04  9:10   ` Hikaru Nishida
2021-11-04  9:10     ` Hikaru Nishida
2021-11-04  9:10     ` Hikaru Nishida
2021-12-04 17:30     ` Marc Zyngier
2021-12-04 17:30       ` Marc Zyngier
2021-12-04 17:30       ` Marc Zyngier
2022-04-06  3:48       ` Hikaru Nishida
2022-04-06  3:48         ` Hikaru Nishida
2022-04-06  3:48         ` Hikaru Nishida

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.