|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] [PATCH 5 of 6] arm: allow ourselves access to all coprocessors in non-secure mode
# HG changeset patch
# User Tim Deegan <tim@xxxxxxx>
# Date 1338482127 -3600
# Node ID 9570c43c07f397d8d4a8e725698c17c10c034d80
# Parent 89f363564aa68dcb78d3aedd6a0b24f9bb1ffc13
arm: allow ourselves access to all coprocessors in non-secure mode
We'll need it to be able top use the VFP extensions, for example.
Signed-off-by: Tim Deegan <tim@xxxxxxx>
diff -r 89f363564aa6 -r 9570c43c07f3 xen/arch/arm/mode_switch.S
--- a/xen/arch/arm/mode_switch.S Thu May 31 17:35:27 2012 +0100
+++ b/xen/arch/arm/mode_switch.S Thu May 31 17:35:27 2012 +0100
@@ -65,7 +65,10 @@ enter_hyp_mode:
mov r0, #0
mcr CP32(r0, FCSEIDR)
mcr CP32(r0, CONTEXTIDR)
- /* FIXME: ought to reset some other NS control regs here */
+ /* Allow non-secure access to coprocessors, FIQs, VFP and NEON */
+ ldr r1, =0x3fff /* 14 CP bits set, all others clear */
+ mcr CP32(r1, NSACR)
+
mrs r0, cpsr /* Copy the CPSR */
add r0, r0, #0x4 /* 0x16 (Monitor) -> 0x1a (Hyp) */
msr spsr_cxsf, r0 /* into the SPSR */
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |