]> git.baikalelectronics.ru Git - kernel.git/commitdiff
KVM: arm64: pkvm: Don't mask already zeroed FEAT_SVE
authorOliver Upton <oupton@google.com>
Mon, 9 May 2022 16:25:59 +0000 (16:25 +0000)
committerMarc Zyngier <maz@kernel.org>
Tue, 10 May 2022 09:58:43 +0000 (10:58 +0100)
FEAT_SVE is already masked by the fixed configuration for
ID_AA64PFR0_EL1; don't try and mask it at runtime.

No functional change intended.

Signed-off-by: Oliver Upton <oupton@google.com>
Reviewed-by: Fuad Tabba <tabba@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20220509162559.2387784-3-oupton@google.com
arch/arm64/kvm/hyp/nvhe/sys_regs.c

index 33f5181af330d07dcd12e08ed7907aa640b8a12a..3f5d7bd171c52f2daed10e4d4087c49d8e2f1110 100644 (file)
@@ -90,9 +90,6 @@ static u64 get_pvm_id_aa64pfr0(const struct kvm_vcpu *vcpu)
        u64 set_mask = 0;
        u64 allow_mask = PVM_ID_AA64PFR0_ALLOW;
 
-       if (!vcpu_has_sve(vcpu))
-               allow_mask &= ~ARM64_FEATURE_MASK(ID_AA64PFR0_SVE);
-
        set_mask |= get_restricted_features_unsigned(id_aa64pfr0_el1_sys_val,
                PVM_ID_AA64PFR0_RESTRICT_UNSIGNED);