diff options
author | Marc Zyngier <marc.zyngier@arm.com> | 2013-06-21 06:57:56 -0400 |
---|---|---|
committer | Christoffer Dall <christoffer.dall@linaro.org> | 2014-07-11 07:57:36 -0400 |
commit | 1a9b13056dde7e3092304d6041ccc60a913042ea (patch) | |
tree | 3e70b5ee93eb9c0bbc8271b240a19cf69a605bb2 /include/kvm | |
parent | 45451914c875bba44903ce4f1445e047b7992bf7 (diff) |
arm64: KVM: split GICv2 world switch from hyp code
Move the GICv2 world switch code into its own file, and add the
necessary indirection to the arm64 switch code.
Also introduce a new type field to the vgic_params structure.
Acked-by: Catalin Marinas <catalin.marinas@arm.com>
Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org>
Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
Diffstat (limited to 'include/kvm')
-rw-r--r-- | include/kvm/arm_vgic.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/include/kvm/arm_vgic.h b/include/kvm/arm_vgic.h index f6b9fec6fcac..65f1121a3beb 100644 --- a/include/kvm/arm_vgic.h +++ b/include/kvm/arm_vgic.h | |||
@@ -24,7 +24,6 @@ | |||
24 | #include <linux/irqreturn.h> | 24 | #include <linux/irqreturn.h> |
25 | #include <linux/spinlock.h> | 25 | #include <linux/spinlock.h> |
26 | #include <linux/types.h> | 26 | #include <linux/types.h> |
27 | #include <linux/irqchip/arm-gic.h> | ||
28 | 27 | ||
29 | #define VGIC_NR_IRQS 256 | 28 | #define VGIC_NR_IRQS 256 |
30 | #define VGIC_NR_SGIS 16 | 29 | #define VGIC_NR_SGIS 16 |
@@ -71,6 +70,10 @@ struct vgic_bytemap { | |||
71 | 70 | ||
72 | struct kvm_vcpu; | 71 | struct kvm_vcpu; |
73 | 72 | ||
73 | enum vgic_type { | ||
74 | VGIC_V2, /* Good ol' GICv2 */ | ||
75 | }; | ||
76 | |||
74 | #define LR_STATE_PENDING (1 << 0) | 77 | #define LR_STATE_PENDING (1 << 0) |
75 | #define LR_STATE_ACTIVE (1 << 1) | 78 | #define LR_STATE_ACTIVE (1 << 1) |
76 | #define LR_STATE_MASK (3 << 0) | 79 | #define LR_STATE_MASK (3 << 0) |
@@ -104,6 +107,8 @@ struct vgic_ops { | |||
104 | }; | 107 | }; |
105 | 108 | ||
106 | struct vgic_params { | 109 | struct vgic_params { |
110 | /* vgic type */ | ||
111 | enum vgic_type type; | ||
107 | /* Physical address of vgic virtual cpu interface */ | 112 | /* Physical address of vgic virtual cpu interface */ |
108 | phys_addr_t vcpu_base; | 113 | phys_addr_t vcpu_base; |
109 | /* Number of list registers */ | 114 | /* Number of list registers */ |