diff options
author | David S. Miller <davem@sunset.davemloft.net> | 2006-02-06 01:27:28 -0500 |
---|---|---|
committer | David S. Miller <davem@sunset.davemloft.net> | 2006-03-20 04:11:50 -0500 |
commit | 45fec05f805a113372c9a7ff4c653ac749f6921c (patch) | |
tree | 36fc99d10656775acb8e9442719447d64ac30a03 /arch/sparc64/kernel/ktlb.S | |
parent | 314981ac7177a933319e3c071a5cf0a579205e6e (diff) |
[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/kernel/ktlb.S')
-rw-r--r-- | arch/sparc64/kernel/ktlb.S | 18 |
1 files changed, 16 insertions, 2 deletions
diff --git a/arch/sparc64/kernel/ktlb.S b/arch/sparc64/kernel/ktlb.S index 9b415ab6db6b..c1335432124e 100644 --- a/arch/sparc64/kernel/ktlb.S +++ b/arch/sparc64/kernel/ktlb.S | |||
@@ -60,8 +60,15 @@ kvmap_itlb_load: | |||
60 | retry | 60 | retry |
61 | 61 | ||
62 | kvmap_itlb_longpath: | 62 | kvmap_itlb_longpath: |
63 | rdpr %pstate, %g5 | 63 | |
64 | 661: rdpr %pstate, %g5 | ||
64 | wrpr %g5, PSTATE_AG | PSTATE_MG, %pstate | 65 | wrpr %g5, PSTATE_AG | PSTATE_MG, %pstate |
66 | .section .gl_2insn_patch, "ax" | ||
67 | .word 661b | ||
68 | nop | ||
69 | nop | ||
70 | .previous | ||
71 | |||
65 | rdpr %tpc, %g5 | 72 | rdpr %tpc, %g5 |
66 | ba,pt %xcc, sparc64_realfault_common | 73 | ba,pt %xcc, sparc64_realfault_common |
67 | mov FAULT_CODE_ITLB, %g4 | 74 | mov FAULT_CODE_ITLB, %g4 |
@@ -161,8 +168,15 @@ kvmap_check_obp: | |||
161 | nop | 168 | nop |
162 | 169 | ||
163 | kvmap_dtlb_longpath: | 170 | kvmap_dtlb_longpath: |
164 | rdpr %pstate, %g5 | 171 | |
172 | 661: rdpr %pstate, %g5 | ||
165 | wrpr %g5, PSTATE_AG | PSTATE_MG, %pstate | 173 | wrpr %g5, PSTATE_AG | PSTATE_MG, %pstate |
174 | .section .gl_2insn_patch, "ax" | ||
175 | .word 661b | ||
176 | nop | ||
177 | nop | ||
178 | .previous | ||
179 | |||
166 | rdpr %tl, %g4 | 180 | rdpr %tl, %g4 |
167 | cmp %g4, 1 | 181 | cmp %g4, 1 |
168 | mov TLB_TAG_ACCESS, %g4 | 182 | mov TLB_TAG_ACCESS, %g4 |