public inbox for linux-arch@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH v3 0/6] Hyper-V: kexec fixes for L1VH (mshv)
@ 2026-04-08  1:36 Jork Loeser
  2026-04-08  1:36 ` [PATCH v3 1/6] Drivers: hv: vmbus: fix hyperv_cpuhp_online variable shadowing Jork Loeser
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: Jork Loeser @ 2026-04-08  1:36 UTC (permalink / raw)
  To: linux-hyperv
  Cc: x86, K . Y . Srinivasan, Haiyang Zhang, Wei Liu, Dexuan Cui,
	Long Li, Thomas Gleixner, Ingo Molnar, Borislav Petkov,
	Dave Hansen, H . Peter Anvin, Arnd Bergmann, Michael Kelley,
	linux-kernel, linux-arch, Jork Loeser

This series fixes kexec support when Linux runs as an L1 Virtual Host
(L1VH) under Hyper-V, using the MSHV driver to manage child VMs.

1. A variable shadowing bug in vmbus that hides the cpuhp state used
   for teardown.

2. Move hv_stimer_global_cleanup() from vmbus's hv_kexec_handler() to
   hv_machine_shutdown(). This ensures stimer cleanup happens before
   the vmbus unload.

3. LP/VP re-creation: after kexec, logical processors and virtual
   processors already exist in the hypervisor. Detect this and skip
   re-adding them.

4-5. SynIC cleanup: the MSHV driver manages its own SynIC resources
     separately from vmbus. Add proper teardown of MSHV-owned SINTs,
     SIMP, and SIEFP on kexec, scoped to only the resources MSHV
     owns.

6. Debugfs stats pages: unmap the VP statistics overlay pages before
   kexec to avoid stale mappings in the new kernel.

Changes since v2:
- Rebased onto linux-next/master to adapt to the upstream SynIC
  refactor (commit 5a674ef871fe, "mshv: refactor synic init and
  cleanup").

Changes since v1:
- Patch 4: account for nested root partitions where VMBus is also
  active (not just L1VH); use a vmbus_active local variable; allocate
  SIRBP L1VH allocation path for when the hypervisor doesn't
  pre-provision the page

Jork Loeser (6):
  Drivers: hv: vmbus: fix hyperv_cpuhp_online variable shadowing
  x86/hyperv: move stimer cleanup to hv_machine_shutdown()
  x86/hyperv: Skip LP/VP creation on kexec
  mshv: limit SynIC management to MSHV-owned resources
  mshv: clean up SynIC state on kexec for L1VH
  mshv: unmap debugfs stats pages on kexec

 arch/x86/kernel/cpu/mshyperv.c |  15 +++-
 drivers/hv/hv_proc.c           |  47 +++++++++++
 drivers/hv/mshv_debugfs.c      |   7 +-
 drivers/hv/mshv_synic.c        | 146 +++++++++++++++++++++------------
 drivers/hv/vmbus_drv.c         |   2 -
 include/asm-generic/mshyperv.h |  10 +++
 include/hyperv/hvgdk_mini.h    |   1 +
 include/hyperv/hvhdk_mini.h    |  12 +++
 8 files changed, 184 insertions(+), 56 deletions(-)

--
2.43.0


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

end of thread, other threads:[~2026-04-08  1:37 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-04-08  1:36 [PATCH v3 0/6] Hyper-V: kexec fixes for L1VH (mshv) Jork Loeser
2026-04-08  1:36 ` [PATCH v3 1/6] Drivers: hv: vmbus: fix hyperv_cpuhp_online variable shadowing Jork Loeser
2026-04-08  1:36 ` [PATCH v3 2/6] x86/hyperv: move stimer cleanup to hv_machine_shutdown() Jork Loeser
2026-04-08  1:36 ` [PATCH v3 3/6] x86/hyperv: Skip LP/VP creation on kexec Jork Loeser
2026-04-08  1:36 ` [PATCH v3 4/6] mshv: limit SynIC management to MSHV-owned resources Jork Loeser
2026-04-08  1:36 ` [PATCH v3 5/6] mshv: clean up SynIC state on kexec for L1VH Jork Loeser
2026-04-08  1:36 ` [PATCH v3 6/6] mshv: unmap debugfs stats pages on kexec Jork Loeser

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox