Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/torvalds/linux.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/arch
diff options
context:
space:
mode:
authorFuad Tabba <tabba@google.com>2022-05-10 12:57:10 +0300
committerMarc Zyngier <maz@kernel.org>2022-05-15 13:26:41 +0300
commit722625c6f4c5b6a9953d6af04c7bb1a6e12830b3 (patch)
tree9668a3a118372d2b4514fb81cc0a7fbfd260d4b3 /arch
parent84d751a019a9792f5b4884e1d598b603c360ec22 (diff)
KVM: arm64: Reenable pmu in Protected Mode
Now that the pmu code does not access hyp data, reenable it in protected mode. Once fully supported, protected VMs will not have pmu support, since that could leak information. However, non-protected VMs in protected mode should have pmu support if available. Signed-off-by: Fuad Tabba <tabba@google.com> Reviewed-by: Oliver Upton <oupton@google.com> Signed-off-by: Marc Zyngier <maz@kernel.org> Link: https://lore.kernel.org/r/20220510095710.148178-5-tabba@google.com
Diffstat (limited to 'arch')
-rw-r--r--arch/arm64/kvm/pmu-emul.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/arch/arm64/kvm/pmu-emul.c b/arch/arm64/kvm/pmu-emul.c
index 78fdc443adc7..dc1779d4c7dd 100644
--- a/arch/arm64/kvm/pmu-emul.c
+++ b/arch/arm64/kvm/pmu-emul.c
@@ -756,8 +756,7 @@ void kvm_host_pmu_init(struct arm_pmu *pmu)
{
struct arm_pmu_entry *entry;
- if (pmu->pmuver == 0 || pmu->pmuver == ID_AA64DFR0_PMUVER_IMP_DEF ||
- is_protected_kvm_enabled())
+ if (pmu->pmuver == 0 || pmu->pmuver == ID_AA64DFR0_PMUVER_IMP_DEF)
return;
mutex_lock(&arm_pmus_lock);