summaryrefslogtreecommitdiff
path: root/arch/arm/kvm/interrupts_head.S
diff options
context:
space:
mode:
authorMarc Zyngier <marc.zyngier@arm.com>2016-01-03 11:26:01 (GMT)
committerMarc Zyngier <marc.zyngier@arm.com>2016-02-29 18:34:12 (GMT)
commitfb32a52a1d4487f3ac5b7ccb659d0beb11ec504f (patch)
treeae4c1660133ab040018cbbd657f08a631f084063 /arch/arm/kvm/interrupts_head.S
parent0ca5565df8ef7534c0d85ec87e6c74f8ebe86e88 (diff)
downloadlinux-fb32a52a1d4487f3ac5b7ccb659d0beb11ec504f.tar.xz
ARM: KVM: Move CP15 array into the CPU context structure
Continuing our rework of the CPU context, we now move the CP15 array into the CPU context structure. As this causes quite a bit of churn, we introduce the vcpu_cp15() macro that abstract the location of the actual array. This will probably help next time we have to revisit that code. Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
Diffstat (limited to 'arch/arm/kvm/interrupts_head.S')
-rw-r--r--arch/arm/kvm/interrupts_head.S3
1 files changed, 2 insertions, 1 deletions
diff --git a/arch/arm/kvm/interrupts_head.S b/arch/arm/kvm/interrupts_head.S
index 51a5950..b9d9531 100644
--- a/arch/arm/kvm/interrupts_head.S
+++ b/arch/arm/kvm/interrupts_head.S
@@ -4,7 +4,8 @@
#define VCPU_USR_REG(_reg_nr) (VCPU_USR_REGS + (_reg_nr * 4))
#define VCPU_USR_SP (VCPU_USR_REG(13))
#define VCPU_USR_LR (VCPU_USR_REG(14))
-#define CP15_OFFSET(_cp15_reg_idx) (VCPU_CP15 + (_cp15_reg_idx * 4))
+#define VCPU_CP15_BASE (VCPU_GUEST_CTXT + CPU_CTXT_CP15)
+#define CP15_OFFSET(_cp15_reg_idx) (VCPU_CP15_BASE + (_cp15_reg_idx * 4))
/*
* Many of these macros need to access the VCPU structure, which is always