From: Oliver Upton Date: Thu, 7 Mar 2024 00:50:48 +0000 (+0000) Subject: Merge branch kvm-arm64/vm-configuration into kvmarm/next X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=0d874858c6bfdaf95f8df26856dbc7a57f3c0128;p=linux.git Merge branch kvm-arm64/vm-configuration into kvmarm/next * kvm-arm64/vm-configuration: (29 commits) : VM configuration enforcement, courtesy of Marc Zyngier : : Userspace has gained the ability to control the features visible : through the ID registers, yet KVM didn't take this into account as the : effective feature set when determing trap / emulation behavior. This : series adds: : : - Mechanism for testing the presence of a particular CPU feature in the : guest's ID registers : : - Infrastructure for computing the effective value of VNCR-backed : registers, taking into account the RES0 / RES1 bits for a particular : VM configuration : : - Implementation of 'fine-grained UNDEF' controls that shadow the FGT : register definitions. KVM: arm64: Don't initialize idreg debugfs w/ preemption disabled KVM: arm64: Fail the idreg iterator if idregs aren't initialized KVM: arm64: Make build-time check of RES0/RES1 bits optional KVM: arm64: Add debugfs file for guest's ID registers KVM: arm64: Snapshot all non-zero RES0/RES1 sysreg fields for later checking KVM: arm64: Make FEAT_MOPS UNDEF if not advertised to the guest KVM: arm64: Make AMU sysreg UNDEF if FEAT_AMU is not advertised to the guest KVM: arm64: Make PIR{,E0}_EL1 UNDEF if S1PIE is not advertised to the guest KVM: arm64: Make TLBI OS/Range UNDEF if not advertised to the guest KVM: arm64: Streamline save/restore of HFG[RW]TR_EL2 KVM: arm64: Move existing feature disabling over to FGU infrastructure KVM: arm64: Propagate and handle Fine-Grained UNDEF bits KVM: arm64: Add Fine-Grained UNDEF tracking information KVM: arm64: Rename __check_nv_sr_forward() to triage_sysreg_trap() KVM: arm64: Use the xarray as the primary sysreg/sysinsn walker KVM: arm64: Register AArch64 system register entries with the sysreg xarray KVM: arm64: Always populate the trap configuration xarray KVM: arm64: nv: Move system instructions to their own sys_reg_desc array KVM: arm64: Drop the requirement for XARRAY_MULTI KVM: arm64: nv: Turn encoding ranges into discrete XArray stores ... Signed-off-by: Oliver Upton --- 0d874858c6bfdaf95f8df26856dbc7a57f3c0128 diff --cc arch/arm64/kvm/arm.c index 090dbc9541574,9b04dbd3aef13..3dee5490eea94 --- a/arch/arm64/kvm/arm.c +++ b/arch/arm64/kvm/arm.c @@@ -190,6 -190,11 +190,10 @@@ vm_fault_t kvm_arch_vcpu_fault(struct k return VM_FAULT_SIGBUS; } -int kvm_arch_create_vm_debugfs(struct kvm *kvm) ++void kvm_arch_create_vm_debugfs(struct kvm *kvm) + { + kvm_sys_regs_create_debugfs(kvm); - return 0; + } /** * kvm_arch_destroy_vm - destroy the VM data structure