On Fri, Apr 03, 2026 at 12:06:12PM -0700, Jork Loeser wrote: > On L1VH, debugfs stats pages are overlay pages: the kernel allocates > them and registers the GPAs with the hypervisor via > HVCALL_MAP_STATS_PAGE2. These overlay mappings persist in the > hypervisor across kexec. If the kexec'd kernel reuses those physical > pages, the hypervisor's overlay semantics cause a machine check > exception. > > Fix this by calling mshv_debugfs_exit() from the reboot notifier, > which issues HVCALL_UNMAP_STATS_PAGE for each mapped stats page before > kexec. This releases the overlay bindings so the physical pages can be > safely reused. Guard mshv_debugfs_exit() against being called when > init failed. > > Signed-off-by: Jork Loeser <[email protected]> > --- > drivers/hv/mshv_debugfs.c | 7 ++++++- > drivers/hv/mshv_root_main.c | 1 + > 2 files changed, 7 insertions(+), 1 deletion(-)
Reviewed-by: Anirudh Rayabharam (Microsoft) <[email protected]>

