summaryrefslogtreecommitdiffstats
path: root/arch/sparc64/mm/ultra.S
diff options
context:
space:
mode:
authorDavid S. Miller2006-02-06 07:27:28 +0100
committerDavid S. Miller2006-03-20 10:11:50 +0100
commit45fec05f805a113372c9a7ff4c653ac749f6921c (patch)
tree36fc99d10656775acb8e9442719447d64ac30a03 /arch/sparc64/mm/ultra.S
parent[SPARC64]: Kill all %pstate changes in context switch code. (diff)
downloadkernel-qcow2-linux-45fec05f805a113372c9a7ff4c653ac749f6921c.tar.gz
kernel-qcow2-linux-45fec05f805a113372c9a7ff4c653ac749f6921c.tar.xz
kernel-qcow2-linux-45fec05f805a113372c9a7ff4c653ac749f6921c.zip
[SPARC64]: Sanitize %pstate writes for sun4v.
If we're just switching between different alternate global sets, nop it out on sun4v. Also, get rid of all of the alternate global save/restore in the OBP CIF trampoline code. Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch/sparc64/mm/ultra.S')
-rw-r--r--arch/sparc64/mm/ultra.S18
1 files changed, 16 insertions, 2 deletions
diff --git a/arch/sparc64/mm/ultra.S b/arch/sparc64/mm/ultra.S
index cac58d66fca9..5dd86ad0d29f 100644
--- a/arch/sparc64/mm/ultra.S
+++ b/arch/sparc64/mm/ultra.S
@@ -444,8 +444,15 @@ xcall_flush_tlb_kernel_range: /* 22 insns */
*/
.globl xcall_sync_tick
xcall_sync_tick:
- rdpr %pstate, %g2
+
+661: rdpr %pstate, %g2
wrpr %g2, PSTATE_IG | PSTATE_AG, %pstate
+ .section .gl_2insn_patch, "ax"
+ .word 661b
+ nop
+ nop
+ .previous
+
rdpr %pil, %g2
wrpr %g0, 15, %pil
sethi %hi(109f), %g7
@@ -468,8 +475,15 @@ xcall_sync_tick:
*/
.globl xcall_report_regs
xcall_report_regs:
- rdpr %pstate, %g2
+
+661: rdpr %pstate, %g2
wrpr %g2, PSTATE_IG | PSTATE_AG, %pstate
+ .section .gl_2insn_patch, "ax"
+ .word 661b
+ nop
+ nop
+ .previous
+
rdpr %pil, %g2
wrpr %g0, 15, %pil
sethi %hi(109f), %g7