diff options
author | Gleb Natapov <gleb@redhat.com> | 2013-10-16 15:30:32 +0300 |
---|---|---|
committer | Gleb Natapov <gleb@redhat.com> | 2013-10-16 15:30:32 +0300 |
commit | d570142674890fe10b3d7d86aa105e3dfce1ddfa (patch) | |
tree | 8a681c3cd9e21400773e24b32f8849d0f25cf4e7 /arch/arm/kvm/reset.c | |
parent | f2e106692d5189303997ad7b96de8d8123aa5613 (diff) | |
parent | a7265fb1751ffbfad553afc7f592a6dac6be48de (diff) | |
download | op-kernel-dev-d570142674890fe10b3d7d86aa105e3dfce1ddfa.zip op-kernel-dev-d570142674890fe10b3d7d86aa105e3dfce1ddfa.tar.gz |
Merge tag 'kvm-arm-for-3.13-1' of git://git.linaro.org/people/cdall/linux-kvm-arm into next
Updates for KVM/ARM including cpu=host and Cortex-A7 support
Diffstat (limited to 'arch/arm/kvm/reset.c')
-rw-r--r-- | arch/arm/kvm/reset.c | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/arch/arm/kvm/reset.c b/arch/arm/kvm/reset.c index 71e08ba..d9bbd83 100644 --- a/arch/arm/kvm/reset.c +++ b/arch/arm/kvm/reset.c @@ -30,16 +30,16 @@ #include <kvm/arm_arch_timer.h> /****************************************************************************** - * Cortex-A15 Reset Values + * Cortex-A15 and Cortex-A7 Reset Values */ -static const int a15_max_cpu_idx = 3; +static const int cortexa_max_cpu_idx = 3; -static struct kvm_regs a15_regs_reset = { +static struct kvm_regs cortexa_regs_reset = { .usr_regs.ARM_cpsr = SVC_MODE | PSR_A_BIT | PSR_I_BIT | PSR_F_BIT, }; -static const struct kvm_irq_level a15_vtimer_irq = { +static const struct kvm_irq_level cortexa_vtimer_irq = { { .irq = 27 }, .level = 1, }; @@ -62,12 +62,13 @@ int kvm_reset_vcpu(struct kvm_vcpu *vcpu) const struct kvm_irq_level *cpu_vtimer_irq; switch (vcpu->arch.target) { + case KVM_ARM_TARGET_CORTEX_A7: case KVM_ARM_TARGET_CORTEX_A15: - if (vcpu->vcpu_id > a15_max_cpu_idx) + if (vcpu->vcpu_id > cortexa_max_cpu_idx) return -EINVAL; - cpu_reset = &a15_regs_reset; + cpu_reset = &cortexa_regs_reset; vcpu->arch.midr = read_cpuid_id(); - cpu_vtimer_irq = &a15_vtimer_irq; + cpu_vtimer_irq = &cortexa_vtimer_irq; break; default: return -ENODEV; |