diff options
author | Marc Zyngier <marc.zyngier@arm.com> | 2013-04-08 11:47:18 -0400 |
---|---|---|
committer | Christoffer Dall <cdall@cs.columbia.edu> | 2013-04-29 01:23:12 -0400 |
commit | 17b1e31f9201fc102ee3ddd409988e47753e22f9 (patch) | |
tree | c500ae28f6c2a4ad2c36c74a9c648f6fee468faf /arch | |
parent | d157f4a5155f4fbd0d1da66b3d2f504c13bd194d (diff) |
ARM: KVM: add architecture specific hook for capabilities
Most of the capabilities are common to both arm and arm64, but
we still need to handle the exceptions.
Introduce kvm_arch_dev_ioctl_check_extension, which both architectures
implement (in the 32bit case, it just returns 0).
Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
Signed-off-by: Christoffer Dall <cdall@cs.columbia.edu>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/arm/include/asm/kvm_host.h | 5 | ||||
-rw-r--r-- | arch/arm/kvm/arm.c | 2 |
2 files changed, 6 insertions, 1 deletions
diff --git a/arch/arm/include/asm/kvm_host.h b/arch/arm/include/asm/kvm_host.h index 6c2a35da867e..dcfcbf59fceb 100644 --- a/arch/arm/include/asm/kvm_host.h +++ b/arch/arm/include/asm/kvm_host.h | |||
@@ -214,6 +214,11 @@ static inline void __cpu_init_hyp_mode(unsigned long long boot_pgd_ptr, | |||
214 | kvm_call_hyp((void*)hyp_stack_ptr, vector_ptr, pgd_ptr); | 214 | kvm_call_hyp((void*)hyp_stack_ptr, vector_ptr, pgd_ptr); |
215 | } | 215 | } |
216 | 216 | ||
217 | static inline int kvm_arch_dev_ioctl_check_extension(long ext) | ||
218 | { | ||
219 | return 0; | ||
220 | } | ||
221 | |||
217 | int kvm_perf_init(void); | 222 | int kvm_perf_init(void); |
218 | int kvm_perf_teardown(void); | 223 | int kvm_perf_teardown(void); |
219 | 224 | ||
diff --git a/arch/arm/kvm/arm.c b/arch/arm/kvm/arm.c index 6ea2aed0d29f..cc67cafc5b87 100644 --- a/arch/arm/kvm/arm.c +++ b/arch/arm/kvm/arm.c | |||
@@ -206,7 +206,7 @@ int kvm_dev_ioctl_check_extension(long ext) | |||
206 | r = KVM_MAX_VCPUS; | 206 | r = KVM_MAX_VCPUS; |
207 | break; | 207 | break; |
208 | default: | 208 | default: |
209 | r = 0; | 209 | r = kvm_arch_dev_ioctl_check_extension(ext); |
210 | break; | 210 | break; |
211 | } | 211 | } |
212 | return r; | 212 | return r; |