[GIT PULL] Second batch of KVM patches for Linux 6.4

From: Paolo Bonzini
Date: Fri May 05 2023 - 06:40:09 EST


Linus,

The following changes since commit 1a5304fecee523060f26e2778d9d8e33c0562df3:

Merge tag 'parisc-for-6.4-1' of git://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux (2023-05-03 19:41:59 -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 7a8016d95651fecce5708ed93a24a03a9ad91c80:

Merge tag 'kvm-s390-next-6.4-2' of https://git.kernel.org/pub/scm/linux/kernel/git/kvms390/linux into HEAD (2023-05-05 06:15:09 -0400)

This includes the 6.4 changes for RISC-V, and a few bugfix patches for
other architectures. For x86, this closes a longstanding performance
issue in the newer and (usually) more scalable page table management code.

If you wish, you can take a look at commit d4fba4dfdcce1 to see the RISC-V
conflicts and their resolution.

----------------------------------------------------------------
RISC-V:
- ONE_REG interface to enable/disable SBI extensions
- Zbb extension for Guest/VM
- AIA CSR virtualization

x86:
- Fix a long-standing TDP MMU flaw, where unloading roots on a vCPU can
result in the root being freed even though the root is completely valid
and can be reused as-is (with a TLB flush).

s390:
- A couple bugfixes.

----------------------------------------------------------------
Andrew Jones (1):
RISC-V: KVM: Alphabetize selects

Anup Patel (10):
RISC-V: KVM: Add ONE_REG interface to enable/disable SBI extensions
RISC-V: KVM: Allow Zbb extension for Guest/VM
RISC-V: Add AIA related CSR defines
RISC-V: Detect AIA CSRs from ISA string
RISC-V: KVM: Drop the _MASK suffix from hgatp.VMID mask defines
RISC-V: KVM: Initial skeletal support for AIA
RISC-V: KVM: Implement subtype for CSR ONE_REG interface
RISC-V: KVM: Add ONE_REG interface for AIA CSRs
RISC-V: KVM: Use bitmap for irqs_pending and irqs_pending_mask
RISC-V: KVM: Virtualize per-HART AIA CSRs

Claudio Imbrenda (2):
KVM: s390: pv: fix asynchronous teardown for small VMs
KVM: s390: fix race in gmap_make_secure()

David Matlack (1):
KVM: RISC-V: Retry fault if vma_lookup() results become invalid

Paolo Bonzini (3):
Merge tag 'kvm-riscv-6.4-1' of https://github.com/kvm-riscv/linux into HEAD
Merge tag 'kvm-x86-mmu-6.4-2' of https://github.com/kvm-x86/linux into HEAD
Merge tag 'kvm-s390-next-6.4-2' of https://git.kernel.org/pub/scm/linux/kernel/git/kvms390/linux into HEAD

Sean Christopherson (1):
KVM: x86: Preserve TDP MMU roots until they are explicitly invalidated

arch/riscv/include/asm/csr.h | 107 +++++++++-
arch/riscv/include/asm/hwcap.h | 8 +
arch/riscv/include/asm/kvm_aia.h | 127 +++++++++++
arch/riscv/include/asm/kvm_host.h | 14 +-
arch/riscv/include/asm/kvm_vcpu_sbi.h | 8 +-
arch/riscv/include/uapi/asm/kvm.h | 51 ++++-
arch/riscv/kernel/cpu.c | 2 +
arch/riscv/kernel/cpufeature.c | 2 +
arch/riscv/kvm/Kconfig | 10 +-
arch/riscv/kvm/Makefile | 1 +
arch/riscv/kvm/aia.c | 388 ++++++++++++++++++++++++++++++++++
arch/riscv/kvm/main.c | 22 +-
arch/riscv/kvm/mmu.c | 28 ++-
arch/riscv/kvm/vcpu.c | 194 +++++++++++++----
arch/riscv/kvm/vcpu_insn.c | 1 +
arch/riscv/kvm/vcpu_sbi.c | 247 ++++++++++++++++++++--
arch/riscv/kvm/vcpu_sbi_base.c | 2 +-
arch/riscv/kvm/vm.c | 4 +
arch/riscv/kvm/vmid.c | 4 +-
arch/s390/kernel/uv.c | 32 +--
arch/s390/kvm/pv.c | 5 +
arch/s390/mm/gmap.c | 7 +
arch/x86/kvm/mmu/tdp_mmu.c | 121 +++++------
23 files changed, 1208 insertions(+), 177 deletions(-)
create mode 100644 arch/riscv/include/asm/kvm_aia.h
create mode 100644 arch/riscv/kvm/aia.c