aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/include
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2014-06-04 11:47:12 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2014-06-04 11:47:12 -0400
commitb05d59dfceaea72565b1648af929b037b0f96d7f (patch)
treebbe92714be468ed8783bce6ac2c305c0aedf8eb5 /arch/arm/include
parentdaf342af2f7856fd2f5c66b9fb39a8f24986ca53 (diff)
parent820b3fcdeb80d30410f4427d2cbf9161c35fdeef (diff)
Merge tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm into next
Pull KVM updates from Paolo Bonzini: "At over 200 commits, covering almost all supported architectures, this was a pretty active cycle for KVM. Changes include: - a lot of s390 changes: optimizations, support for migration, GDB support and more - ARM changes are pretty small: support for the PSCI 0.2 hypercall interface on both the guest and the host (the latter acked by Catalin) - initial POWER8 and little-endian host support - support for running u-boot on embedded POWER targets - pretty large changes to MIPS too, completing the userspace interface and improving the handling of virtualized timer hardware - for x86, a larger set of changes is scheduled for 3.17. Still, we have a few emulator bugfixes and support for running nested fully-virtualized Xen guests (para-virtualized Xen guests have always worked). And some optimizations too. The only missing architecture here is ia64. It's not a coincidence that support for KVM on ia64 is scheduled for removal in 3.17" * tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm: (203 commits) KVM: add missing cleanup_srcu_struct KVM: PPC: Book3S PR: Rework SLB switching code KVM: PPC: Book3S PR: Use SLB entry 0 KVM: PPC: Book3S HV: Fix machine check delivery to guest KVM: PPC: Book3S HV: Work around POWER8 performance monitor bugs KVM: PPC: Book3S HV: Make sure we don't miss dirty pages KVM: PPC: Book3S HV: Fix dirty map for hugepages KVM: PPC: Book3S HV: Put huge-page HPTEs in rmap chain for base address KVM: PPC: Book3S HV: Fix check for running inside guest in global_invalidates() KVM: PPC: Book3S: Move KVM_REG_PPC_WORT to an unused register number KVM: PPC: Book3S: Add ONE_REG register names that were missed KVM: PPC: Add CAP to indicate hcall fixes KVM: PPC: MPIC: Reset IRQ source private members KVM: PPC: Graciously fail broken LE hypercalls PPC: ePAPR: Fix hypercall on LE guest KVM: PPC: BOOK3S: Remove open coded make_dsisr in alignment handler KVM: PPC: BOOK3S: Always use the saved DAR value PPC: KVM: Make NX bit available with magic page KVM: PPC: Disable NX for old magic page using guests KVM: PPC: BOOK3S: HV: Add mixed page-size support for guest ...
Diffstat (limited to 'arch/arm/include')
-rw-r--r--arch/arm/include/asm/kvm_host.h2
-rw-r--r--arch/arm/include/asm/kvm_psci.h6
-rw-r--r--arch/arm/include/asm/psci.h7
-rw-r--r--arch/arm/include/uapi/asm/kvm.h10
4 files changed, 17 insertions, 8 deletions
diff --git a/arch/arm/include/asm/kvm_host.h b/arch/arm/include/asm/kvm_host.h
index 09af14999c9b..193ceaf01bfd 100644
--- a/arch/arm/include/asm/kvm_host.h
+++ b/arch/arm/include/asm/kvm_host.h
@@ -36,7 +36,7 @@
36#define KVM_COALESCED_MMIO_PAGE_OFFSET 1 36#define KVM_COALESCED_MMIO_PAGE_OFFSET 1
37#define KVM_HAVE_ONE_REG 37#define KVM_HAVE_ONE_REG
38 38
39#define KVM_VCPU_MAX_FEATURES 1 39#define KVM_VCPU_MAX_FEATURES 2
40 40
41#include <kvm/arm_vgic.h> 41#include <kvm/arm_vgic.h>
42 42
diff --git a/arch/arm/include/asm/kvm_psci.h b/arch/arm/include/asm/kvm_psci.h
index 9a83d98bf170..6bda945d31fa 100644
--- a/arch/arm/include/asm/kvm_psci.h
+++ b/arch/arm/include/asm/kvm_psci.h
@@ -18,6 +18,10 @@
18#ifndef __ARM_KVM_PSCI_H__ 18#ifndef __ARM_KVM_PSCI_H__
19#define __ARM_KVM_PSCI_H__ 19#define __ARM_KVM_PSCI_H__
20 20
21bool kvm_psci_call(struct kvm_vcpu *vcpu); 21#define KVM_ARM_PSCI_0_1 1
22#define KVM_ARM_PSCI_0_2 2
23
24int kvm_psci_version(struct kvm_vcpu *vcpu);
25int kvm_psci_call(struct kvm_vcpu *vcpu);
22 26
23#endif /* __ARM_KVM_PSCI_H__ */ 27#endif /* __ARM_KVM_PSCI_H__ */
diff --git a/arch/arm/include/asm/psci.h b/arch/arm/include/asm/psci.h
index c4ae171850f8..c25ef3ec6d1f 100644
--- a/arch/arm/include/asm/psci.h
+++ b/arch/arm/include/asm/psci.h
@@ -29,16 +29,19 @@ struct psci_operations {
29 int (*cpu_off)(struct psci_power_state state); 29 int (*cpu_off)(struct psci_power_state state);
30 int (*cpu_on)(unsigned long cpuid, unsigned long entry_point); 30 int (*cpu_on)(unsigned long cpuid, unsigned long entry_point);
31 int (*migrate)(unsigned long cpuid); 31 int (*migrate)(unsigned long cpuid);
32 int (*affinity_info)(unsigned long target_affinity,
33 unsigned long lowest_affinity_level);
34 int (*migrate_info_type)(void);
32}; 35};
33 36
34extern struct psci_operations psci_ops; 37extern struct psci_operations psci_ops;
35extern struct smp_operations psci_smp_ops; 38extern struct smp_operations psci_smp_ops;
36 39
37#ifdef CONFIG_ARM_PSCI 40#ifdef CONFIG_ARM_PSCI
38void psci_init(void); 41int psci_init(void);
39bool psci_smp_available(void); 42bool psci_smp_available(void);
40#else 43#else
41static inline void psci_init(void) { } 44static inline int psci_init(void) { return 0; }
42static inline bool psci_smp_available(void) { return false; } 45static inline bool psci_smp_available(void) { return false; }
43#endif 46#endif
44 47
diff --git a/arch/arm/include/uapi/asm/kvm.h b/arch/arm/include/uapi/asm/kvm.h
index ef0c8785ba16..e6ebdd3471e5 100644
--- a/arch/arm/include/uapi/asm/kvm.h
+++ b/arch/arm/include/uapi/asm/kvm.h
@@ -20,6 +20,7 @@
20#define __ARM_KVM_H__ 20#define __ARM_KVM_H__
21 21
22#include <linux/types.h> 22#include <linux/types.h>
23#include <linux/psci.h>
23#include <asm/ptrace.h> 24#include <asm/ptrace.h>
24 25
25#define __KVM_HAVE_GUEST_DEBUG 26#define __KVM_HAVE_GUEST_DEBUG
@@ -83,6 +84,7 @@ struct kvm_regs {
83#define KVM_VGIC_V2_CPU_SIZE 0x2000 84#define KVM_VGIC_V2_CPU_SIZE 0x2000
84 85
85#define KVM_ARM_VCPU_POWER_OFF 0 /* CPU is started in OFF state */ 86#define KVM_ARM_VCPU_POWER_OFF 0 /* CPU is started in OFF state */
87#define KVM_ARM_VCPU_PSCI_0_2 1 /* CPU uses PSCI v0.2 */
86 88
87struct kvm_vcpu_init { 89struct kvm_vcpu_init {
88 __u32 target; 90 __u32 target;
@@ -201,9 +203,9 @@ struct kvm_arch_memory_slot {
201#define KVM_PSCI_FN_CPU_ON KVM_PSCI_FN(2) 203#define KVM_PSCI_FN_CPU_ON KVM_PSCI_FN(2)
202#define KVM_PSCI_FN_MIGRATE KVM_PSCI_FN(3) 204#define KVM_PSCI_FN_MIGRATE KVM_PSCI_FN(3)
203 205
204#define KVM_PSCI_RET_SUCCESS 0 206#define KVM_PSCI_RET_SUCCESS PSCI_RET_SUCCESS
205#define KVM_PSCI_RET_NI ((unsigned long)-1) 207#define KVM_PSCI_RET_NI PSCI_RET_NOT_SUPPORTED
206#define KVM_PSCI_RET_INVAL ((unsigned long)-2) 208#define KVM_PSCI_RET_INVAL PSCI_RET_INVALID_PARAMS
207#define KVM_PSCI_RET_DENIED ((unsigned long)-3) 209#define KVM_PSCI_RET_DENIED PSCI_RET_DENIED
208 210
209#endif /* __ARM_KVM_H__ */ 211#endif /* __ARM_KVM_H__ */