Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/sparc64/sparc64 Decrement %tl in trap handler not t...
details: https://anonhg.NetBSD.org/src/rev/74adee702df3
branches: trunk
changeset: 345316:74adee702df3
user: nakayama <nakayama%NetBSD.org@localhost>
date: Wed May 18 15:14:08 2016 +0000
description:
Decrement %tl in trap handler not to make it zero unconditionally
for the nested trap, and remove useless mov.
diffstat:
sys/arch/sparc64/sparc64/locore.s | 8 +++++---
1 files changed, 5 insertions(+), 3 deletions(-)
diffs (36 lines):
diff -r 571c0d785786 -r 74adee702df3 sys/arch/sparc64/sparc64/locore.s
--- a/sys/arch/sparc64/sparc64/locore.s Wed May 18 11:28:44 2016 +0000
+++ b/sys/arch/sparc64/sparc64/locore.s Wed May 18 15:14:08 2016 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: locore.s,v 1.396 2016/05/17 19:43:28 palle Exp $ */
+/* $NetBSD: locore.s,v 1.397 2016/05/18 15:14:08 nakayama Exp $ */
/*
* Copyright (c) 2006-2010 Matthew R. Green
@@ -7147,7 +7147,6 @@
wrpr %g0, PSTATE_KERN, %pstate ! Get back to normal globals
stx %g1, [%sp + CC64FSZ + STKB + TF_G + ( 1*8)]
- mov %g1, %o1 ! code
rdpr %tpc, %o2 ! (pc)
stx %g2, [%sp + CC64FSZ + STKB + TF_G + ( 2*8)]
rdpr %tstate, %g1
@@ -7157,7 +7156,6 @@
rd %y, %o4
stx %g5, [%sp + CC64FSZ + STKB + TF_G + ( 5*8)]
stx %g6, [%sp + CC64FSZ + STKB + TF_G + ( 6*8)]
- wrpr %g0, 0, %tl ! return to tl=0
stx %g7, [%sp + CC64FSZ + STKB + TF_G + ( 7*8)]
stx %g1, [%sp + CC64FSZ + STKB + TF_TSTATE]
@@ -7169,6 +7167,10 @@
stb %g5, [%sp + CC64FSZ + STKB + TF_PIL]
stb %g5, [%sp + CC64FSZ + STKB + TF_OLDPIL]
+ rdpr %tl, %g7
+ dec %g7
+ movrlz %g7, %g0, %g7
+ wrpr %g0, %g7, %tl
!! In the EMBEDANY memory model %g4 points to the start of the data segment.
!! In our case we need to clear it before calling any C-code
clr %g4
Home |
Main Index |
Thread Index |
Old Index