diff options
author | Marc Zyngier <marc.zyngier@arm.com> | 2012-10-15 07:09:45 -0400 |
---|---|---|
committer | Christoffer Dall <cdall@cs.columbia.edu> | 2013-03-06 18:48:44 -0500 |
commit | 728d577d357c9caf83f75d0a38f318f343999cc2 (patch) | |
tree | 1b2fa2fcc4960b3a673476e6ead79461c9a210b4 /arch/arm/kvm/arm.c | |
parent | b4034bde5f168f2383a54b4573e1e440dbc169cf (diff) |
ARM: KVM: move kvm_target_cpu to guest.c
guest.c already contains some target-specific checks. Let's move
kvm_target_cpu() over there so arm.c is mostly target agnostic.
Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
Diffstat (limited to 'arch/arm/kvm/arm.c')
-rw-r--r-- | arch/arm/kvm/arm.c | 17 |
1 files changed, 0 insertions, 17 deletions
diff --git a/arch/arm/kvm/arm.c b/arch/arm/kvm/arm.c index f0530499dec6..c10a45fa73f7 100644 --- a/arch/arm/kvm/arm.c +++ b/arch/arm/kvm/arm.c | |||
@@ -33,7 +33,6 @@ | |||
33 | #include <asm/uaccess.h> | 33 | #include <asm/uaccess.h> |
34 | #include <asm/ptrace.h> | 34 | #include <asm/ptrace.h> |
35 | #include <asm/mman.h> | 35 | #include <asm/mman.h> |
36 | #include <asm/cputype.h> | ||
37 | #include <asm/tlbflush.h> | 36 | #include <asm/tlbflush.h> |
38 | #include <asm/cacheflush.h> | 37 | #include <asm/cacheflush.h> |
39 | #include <asm/virt.h> | 38 | #include <asm/virt.h> |
@@ -301,22 +300,6 @@ int kvm_cpu_has_pending_timer(struct kvm_vcpu *vcpu) | |||
301 | return 0; | 300 | return 0; |
302 | } | 301 | } |
303 | 302 | ||
304 | int __attribute_const__ kvm_target_cpu(void) | ||
305 | { | ||
306 | unsigned long implementor = read_cpuid_implementor(); | ||
307 | unsigned long part_number = read_cpuid_part_number(); | ||
308 | |||
309 | if (implementor != ARM_CPU_IMP_ARM) | ||
310 | return -EINVAL; | ||
311 | |||
312 | switch (part_number) { | ||
313 | case ARM_CPU_PART_CORTEX_A15: | ||
314 | return KVM_ARM_TARGET_CORTEX_A15; | ||
315 | default: | ||
316 | return -EINVAL; | ||
317 | } | ||
318 | } | ||
319 | |||
320 | int kvm_arch_vcpu_init(struct kvm_vcpu *vcpu) | 303 | int kvm_arch_vcpu_init(struct kvm_vcpu *vcpu) |
321 | { | 304 | { |
322 | int ret; | 305 | int ret; |