summaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorChristoffer Dall <christoffer.dall@linaro.org>2013-11-16 19:51:25 +0100
committerChristoffer Dall <christoffer.dall@linaro.org>2013-12-21 18:58:57 +0100
commita1a64387adeeba7a34ce06f2774e81f496ee803b (patch)
tree963fdf9b52a832d731ab35f955ee8a2d20c9ad18 /arch
parentKVM: MMU: handle invalid root_hpa at __direct_map (diff)
downloadlinux-a1a64387adeeba7a34ce06f2774e81f496ee803b.tar.xz
linux-a1a64387adeeba7a34ce06f2774e81f496ee803b.zip
arm/arm64: KVM: arch_timer: Initialize cntvoff at kvm_init
Initialize the cntvoff at kvm_init_vm time, not before running the VCPUs at the first time because that will overwrite any potentially restored values from user space. Cc: Andre Przywara <andre.przywara@linaro.org> Acked-by: Marc Zynger <marc.zyngier@arm.com> Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org>
Diffstat (limited to 'arch')
-rw-r--r--arch/arm/kvm/arm.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/arm/kvm/arm.c b/arch/arm/kvm/arm.c
index 2a700e00528d..13205bd9b359 100644
--- a/arch/arm/kvm/arm.c
+++ b/arch/arm/kvm/arm.c
@@ -137,6 +137,8 @@ int kvm_arch_init_vm(struct kvm *kvm, unsigned long type)
if (ret)
goto out_free_stage2_pgd;
+ kvm_timer_init(kvm);
+
/* Mark the initial VMID generation invalid */
kvm->arch.vmid_gen = 0;