[GIT PULL] KVM/riscv changes for 6.18

Paolo Bonzini pbonzini at redhat.com
Tue Sep 30 10:16:15 PDT 2025


On Thu, Sep 25, 2025 at 9:00 AM Anup Patel <anup at brainfault.org> wrote:
>
> Hi Paolo,
>
> We have the following KVM RISC-V changes for 6.18:
> 1) Added SBI FWFT extension for Guest/VM along with
>     corresponding ONE_REG interface
> 2) Added Zicbop and bfloat16 extensions for Guest/VM
> 3) Enabled more common KVM selftests for RISC-V
> 4) Added SBI v3.0 PMU enhancements in KVM and
>     perf driver
>
> The perf driver changes in #4 above are going through
> KVM RISC-V tree based discussion with Will and Paul [1].

Pulled, thanks.

Paolo

> Please pull.
>
> [1] - https://lore.kernel.org/all/CAAhSdy3wJd5uicJntf+WgTaLciiQsqT1QfUmrZ1Jk9qEONRgPw@mail.gmail.com/
>
> Regards,
> Anup
>
> The following changes since commit 76eeb9b8de9880ca38696b2fb56ac45ac0a25c6c:
>
>   Linux 6.17-rc5 (2025-09-07 14:22:57 -0700)
>
> are available in the Git repository at:
>
>   https://github.com/kvm-riscv/linux.git tags/kvm-riscv-6.18-1
>
> for you to fetch changes up to dbdadd943a278fb8a24ae4199a668131108034b4:
>
>   RISC-V: KVM: Upgrade the supported SBI version to 3.0 (2025-09-16
> 11:49:31 +0530)
>
> ----------------------------------------------------------------
> KVM/riscv changes for 6.18
>
> - Added SBI FWFT extension for Guest/VM with misaligned
>   delegation and pointer masking PMLEN features
> - Added ONE_REG interface for SBI FWFT extension
> - Added Zicbop and bfloat16 extensions for Guest/VM
> - Enabled more common KVM selftests for RISC-V such as
>   access_tracking_perf_test, dirty_log_perf_test,
>   memslot_modification_stress_test, memslot_perf_test,
>   mmu_stress_test, and rseq_test
> - Added SBI v3.0 PMU enhancements in KVM and perf driver
>
> ----------------------------------------------------------------
> Anup Patel (6):
>       RISC-V: KVM: Set initial value of hedeleg in kvm_arch_vcpu_create()
>       RISC-V: KVM: Introduce feature specific reset for SBI FWFT
>       RISC-V: KVM: Introduce optional ONE_REG callbacks for SBI extensions
>       RISC-V: KVM: Move copy_sbi_ext_reg_indices() to SBI implementation
>       RISC-V: KVM: Implement ONE_REG interface for SBI FWFT state
>       KVM: riscv: selftests: Add SBI FWFT to get-reg-list test
>
> Atish Patra (8):
>       drivers/perf: riscv: Add SBI v3.0 flag
>       drivers/perf: riscv: Add raw event v2 support
>       RISC-V: KVM: Add support for Raw event v2
>       drivers/perf: riscv: Implement PMU event info function
>       drivers/perf: riscv: Export PMU event info function
>       RISC-V: KVM: No need of explicit writable slot check
>       RISC-V: KVM: Implement get event info function
>       RISC-V: KVM: Upgrade the supported SBI version to 3.0
>
> Clément Léger (2):
>       RISC-V: KVM: add support for FWFT SBI extension
>       RISC-V: KVM: add support for SBI_FWFT_MISALIGNED_DELEG
>
> Dong Yang (1):
>       KVM: riscv: selftests: Add missing headers for new testcases
>
> Fangyu Yu (1):
>       RISC-V: KVM: Write hgatp register with valid mode bits
>
> Guo Ren (Alibaba DAMO Academy) (2):
>       RISC-V: KVM: Remove unnecessary HGATP csr_read
>       RISC-V: KVM: Prevent HGATP_MODE_BARE passed
>
> Quan Zhou (8):
>       RISC-V: KVM: Change zicbom/zicboz block size to depend on the host isa
>       RISC-V: KVM: Provide UAPI for Zicbop block size
>       RISC-V: KVM: Allow Zicbop extension for Guest/VM
>       RISC-V: KVM: Allow bfloat16 extension for Guest/VM
>       KVM: riscv: selftests: Add Zicbop extension to get-reg-list test
>       KVM: riscv: selftests: Add bfloat16 extension to get-reg-list test
>       KVM: riscv: selftests: Use the existing RISCV_FENCE macro in
> `rseq-riscv.h`
>       KVM: riscv: selftests: Add common supported test cases
>
> Samuel Holland (1):
>       RISC-V: KVM: Add support for SBI_FWFT_POINTER_MASKING_PMLEN
>
>  arch/riscv/include/asm/kvm_host.h                  |   4 +
>  arch/riscv/include/asm/kvm_vcpu_pmu.h              |   3 +
>  arch/riscv/include/asm/kvm_vcpu_sbi.h              |  25 +-
>  arch/riscv/include/asm/kvm_vcpu_sbi_fwft.h         |  34 ++
>  arch/riscv/include/asm/sbi.h                       |  13 +
>  arch/riscv/include/uapi/asm/kvm.h                  |  21 +
>  arch/riscv/kvm/Makefile                            |   1 +
>  arch/riscv/kvm/gstage.c                            |  27 +-
>  arch/riscv/kvm/main.c                              |  33 +-
>  arch/riscv/kvm/vcpu.c                              |   3 +-
>  arch/riscv/kvm/vcpu_onereg.c                       |  95 ++--
>  arch/riscv/kvm/vcpu_pmu.c                          |  74 ++-
>  arch/riscv/kvm/vcpu_sbi.c                          | 176 ++++++-
>  arch/riscv/kvm/vcpu_sbi_fwft.c                     | 544 +++++++++++++++++++++
>  arch/riscv/kvm/vcpu_sbi_pmu.c                      |   3 +
>  arch/riscv/kvm/vcpu_sbi_sta.c                      |  72 +--
>  arch/riscv/kvm/vmid.c                              |   8 +-
>  drivers/perf/riscv_pmu_sbi.c                       | 191 ++++++--
>  include/linux/perf/riscv_pmu.h                     |   1 +
>  tools/testing/selftests/kvm/Makefile.kvm           |   6 +
>  .../selftests/kvm/access_tracking_perf_test.c      |   1 +
>  .../selftests/kvm/include/riscv/processor.h        |   1 +
>  .../kvm/memslot_modification_stress_test.c         |   1 +
>  tools/testing/selftests/kvm/memslot_perf_test.c    |   1 +
>  tools/testing/selftests/kvm/riscv/get-reg-list.c   |  60 +++
>  tools/testing/selftests/rseq/rseq-riscv.h          |   3 +-
>  26 files changed, 1188 insertions(+), 213 deletions(-)
>  create mode 100644 arch/riscv/include/asm/kvm_vcpu_sbi_fwft.h
>  create mode 100644 arch/riscv/kvm/vcpu_sbi_fwft.c
>




More information about the kvm-riscv mailing list