[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20251018145533.2072927-1-pbonzini@redhat.com>
Date: Sat, 18 Oct 2025 16:55:32 +0200
From: Paolo Bonzini <pbonzini@...hat.com>
To: torvalds@...ux-foundation.org
Cc: linux-kernel@...r.kernel.org,
kvm@...r.kernel.org,
maz@...nel.org,
seanjc@...gle.com
Subject: [GIT PULL] KVM fixes for Linux 6.18-rc2
Linus,
The following changes since commit 3a8660878839faadb4f1a6dd72c3179c1df56787:
Linux 6.18-rc1 (2025-10-12 13:42:36 -0700)
are available in the Git repository at:
https://git.kernel.org/pub/scm/virt/kvm/kvm.git tags/for-linus
for you to fetch changes up to 4361f5aa8bfcecbab3fc8db987482b9e08115a6a:
Merge tag 'kvm-x86-fixes-6.18-rc2' of https://github.com/kvm-x86/linux into HEAD (2025-10-18 10:25:43 +0200)
For the most part, these are fixes and tests for either Arm or guest_memfd.
----------------------------------------------------------------
ARM:
- Fix the handling of ZCR_EL2 in NV VMs
- Pick the correct translation regime when doing a PTW on
the back of a SEA
- Prevent userspace from injecting an event into a vcpu that isn't
initialised yet
- Move timer save/restore to the sysreg handling code, fixing EL2 timer
access in the process
- Add FGT-based trapping of MDSCR_EL1 to reduce the overhead of debug
- Fix trapping configuration when the host isn't GICv3
- Improve the detection of HCR_EL2.E2H being RES1
- Drop a spurious 'break' statement in the S1 PTW
- Don't try to access SPE when owned by EL3
Documentation updates:
- Document the failure modes of event injection
- Document that a GICv3 guest can be created on a GICv5 host
with FEAT_GCIE_LEGACY
Selftest improvements:
- Add a selftest for the effective value of HCR_EL2.AMO
- Address build warning in the timer selftest when building with clang
- Teach irqfd selftests about non-x86 architectures
- Add missing sysregs to the set_id_regs selftest
- Fix vcpu allocation in the vgic_lpi_stress selftest
- Correctly enable interrupts in the vgic_lpi_stress selftest
x86:
- Expand the KVM_PRE_FAULT_MEMORY selftest to add a regression test for the
bug fixed by commit 3ccbf6f47098 ("KVM: x86/mmu: Return -EAGAIN if userspace
deletes/moves memslot during prefault")
- Don't try to get PMU capabilities from perf when running a CPU with hybrid
CPUs/PMUs, as perf will rightly WARN.
guest_memfd:
- Rework KVM_CAP_GUEST_MEMFD_MMAP (newly introduced in 6.18) into a more
generic KVM_CAP_GUEST_MEMFD_FLAGS
- Add a guest_memfd INIT_SHARED flag and require userspace to explicitly set
said flag to initialize memory as SHARED, irrespective of MMAP. The
behavior merged in 6.18 is that enabling mmap() implicitly initializes
memory as SHARED, which would result in an ABI collision for x86 CoCo VMs
as their memory is currently always initialized PRIVATE.
- Allow mmap() on guest_memfd for x86 CoCo VMs, i.e. on VMs with private
memory, to enable testing such setups, i.e. to hopefully flush out any
other lurking ABI issues before 6.18 is officially released.
- Add testcases to the guest_memfd selftest to cover guest_memfd without MMAP,
and host userspace accesses to mmap()'d private memory.
----------------------------------------------------------------
Ackerley Tng (1):
KVM: selftests: Add test coverage for guest_memfd without GUEST_MEMFD_FLAG_MMAP
Dapeng Mi (1):
KVM: x86/pmu: Don't try to get perf capabilities for hybrid CPUs
Marc Zyngier (15):
KVM: arm64: nv: Don't advance PC when pending an SVE exception
KVM: arm64: Hide CNTHV_*_EL2 from userspace for nVHE guests
KVM: arm64: Introduce timer_context_to_vcpu() helper
KVM: arm64: Replace timer context vcpu pointer with timer_id
KVM: arm64: Make timer_set_offset() generally accessible
KVM: arm64: Add timer UAPI workaround to sysreg infrastructure
KVM: arm64: Move CNT*_CTL_EL0 userspace accessors to generic infrastructure
KVM: arm64: Move CNT*_CVAL_EL0 userspace accessors to generic infrastructure
KVM: arm64: Move CNT*CT_EL0 userspace accessors to generic infrastructure
KVM: arm64: Fix WFxT handling of nested virt
KVM: arm64: Kill leftovers of ad-hoc timer userspace access
KVM: arm64: selftests: Make dependencies on VHE-specific registers explicit
KVM: arm64: selftests: Add an E2H=0-specific configuration to get_reg_list
KVM: arm64: selftests: Fix misleading comment about virtual timer encoding
arm64: Revamp HCR_EL2.E2H RES1 detection
Mukesh Ojha (1):
KVM: arm64: Guard PMSCR_EL1 initialization with SPE presence check
Oliver Upton (9):
KVM: arm64: nv: Don't treat ZCR_EL2 as a 'mapped' register
KVM: arm64: Use the in-context stage-1 in __kvm_find_s1_desc_level()
KVM: arm64: selftests: Test effective value of HCR_EL2.AMO
KVM: arm64: Prevent access to vCPU events before init
KVM: arm64: Document vCPU event ioctls as requiring init'ed vCPU
KVM: selftests: Fix irqfd_test for non-x86 architectures
KVM: arm64: selftests: Actually enable IRQs in vgic_lpi_stress
KVM: arm64: Compute per-vCPU FGTs at vcpu_load()
KVM: arm64: nv: Use FGT write trap of MDSCR_EL1 when available
Osama Abdelkader (1):
KVM: arm64: Remove unreachable break after return
Paolo Bonzini (2):
Merge tag 'kvmarm-fixes-6.18-1' of git://git.kernel.org/pub/scm/linux/kernel/git/kvmarm/kvmarm into HEAD
Merge tag 'kvm-x86-fixes-6.18-rc2' of https://github.com/kvm-x86/linux into HEAD
Sascha Bischoff (2):
KVM: arm64: gic-v3: Only set ICH_HCR traps for v2-on-v3 or v3 guests
Documentation: KVM: Update GICv3 docs for GICv5 hosts
Sean Christopherson (13):
KVM: Rework KVM_CAP_GUEST_MEMFD_MMAP into KVM_CAP_GUEST_MEMFD_FLAGS
KVM: guest_memfd: Add INIT_SHARED flag, reject user page faults if not set
KVM: guest_memfd: Invalidate SHARED GPAs if gmem supports INIT_SHARED
KVM: Explicitly mark KVM_GUEST_MEMFD as depending on KVM_GENERIC_MMU_NOTIFIER
KVM: guest_memfd: Allow mmap() on guest_memfd for x86 VMs with private memory
KVM: selftests: Stash the host page size in a global in the guest_memfd test
KVM: selftests: Create a new guest_memfd for each testcase
KVM: selftests: Add wrappers for mmap() and munmap() to assert success
KVM: selftests: Isolate the guest_memfd Copy-on-Write negative testcase
KVM: selftests: Add wrapper macro to handle and assert on expected SIGBUS
KVM: selftests: Verify that faulting in private guest_memfd memory fails
KVM: selftests: Verify that reads to inaccessible guest_memfd VMAs SIGBUS
KVM: arm64: selftests: Track width of timer counter as "int", not "uint64_t"
Yan Zhao (1):
KVM: selftests: Test prefault memory during concurrent memslot removal
Zenghui Yu (2):
KVM: arm64: selftests: Sync ID_AA64PFR1, MPIDR, CLIDR in guest
KVM: arm64: selftests: Allocate vcpus with correct size
Documentation/virt/kvm/api.rst | 20 ++-
Documentation/virt/kvm/devices/arm-vgic-v3.rst | 3 +-
arch/arm64/include/asm/el2_setup.h | 38 ++++-
arch/arm64/include/asm/kvm_host.h | 50 ++++++
arch/arm64/kvm/arch_timer.c | 105 ++-----------
arch/arm64/kvm/arm.c | 7 +
arch/arm64/kvm/at.c | 7 +-
arch/arm64/kvm/config.c | 90 +++++++++++
arch/arm64/kvm/debug.c | 15 +-
arch/arm64/kvm/guest.c | 70 ---------
arch/arm64/kvm/handle_exit.c | 7 +-
arch/arm64/kvm/hyp/include/hyp/switch.h | 148 ++----------------
arch/arm64/kvm/hyp/nvhe/pkvm.c | 1 +
arch/arm64/kvm/nested.c | 9 +-
arch/arm64/kvm/sys_regs.c | 131 ++++++++++++----
arch/arm64/kvm/sys_regs.h | 6 +
arch/arm64/kvm/vgic/vgic-v3.c | 5 +-
arch/x86/kvm/pmu.c | 8 +-
arch/x86/kvm/x86.c | 7 +-
include/kvm/arm_arch_timer.h | 24 ++-
include/linux/kvm_host.h | 12 +-
include/uapi/linux/kvm.h | 5 +-
.../selftests/kvm/arm64/arch_timer_edge_cases.c | 2 +-
.../testing/selftests/kvm/arm64/external_aborts.c | 43 ++++++
tools/testing/selftests/kvm/arm64/get-reg-list.c | 99 +++++++++++-
tools/testing/selftests/kvm/arm64/set_id_regs.c | 3 +
.../testing/selftests/kvm/arm64/vgic_lpi_stress.c | 3 +-
tools/testing/selftests/kvm/guest_memfd_test.c | 171 +++++++++++----------
.../selftests/kvm/include/arm64/processor.h | 12 +-
tools/testing/selftests/kvm/include/kvm_util.h | 27 ++++
tools/testing/selftests/kvm/include/test_util.h | 19 +++
tools/testing/selftests/kvm/irqfd_test.c | 14 +-
tools/testing/selftests/kvm/lib/arm64/processor.c | 5 +
tools/testing/selftests/kvm/lib/kvm_util.c | 49 +++---
tools/testing/selftests/kvm/lib/s390/processor.c | 5 +
tools/testing/selftests/kvm/lib/test_util.c | 7 +
tools/testing/selftests/kvm/lib/x86/processor.c | 5 +
tools/testing/selftests/kvm/mmu_stress_test.c | 5 +-
.../testing/selftests/kvm/pre_fault_memory_test.c | 131 ++++++++++++++--
tools/testing/selftests/kvm/s390/ucontrol_test.c | 16 +-
.../testing/selftests/kvm/set_memory_region_test.c | 17 +-
virt/kvm/Kconfig | 1 +
virt/kvm/guest_memfd.c | 75 +++++----
virt/kvm/kvm_main.c | 4 +-
44 files changed, 941 insertions(+), 540 deletions(-)
Powered by blists - more mailing lists