push trap conversion up into tl1_trap to further simplify spill / fill fault

handling
This commit is contained in:
Kip Macy 2006-12-18 02:40:23 +00:00
parent 423c28ab10
commit 0578eca08a
2 changed files with 10 additions and 14 deletions

View File

@ -1999,6 +1999,12 @@ ENTRY(tl1_trap)
wrpr %g0, 1, %gl
rdpr %tt, %g2
GET_MMFSA_SCRATCH(%g7)
! convert hardware trap type to kernel trap type
set trap_conversion, %g1
sllx %g2, INT_SHIFT, %g2
ld [%g1 + %g2], %g2
wr %g0, ASI_REAL, %asi
ldxa [%g7 + MMFSA_D_ADDR]%asi, %g3
ldxa [%g7 + MMFSA_D_CTX]%asi, %g7

View File

@ -37,17 +37,12 @@ ENTRY(fault_64bit_sn0)
mov 1, %g5
stx %g5, [%g4 + PCB_NSAVED]
! convert hardware trap type to kernel trap type
set trap_conversion, %g1
sllx %g2, INT_SHIFT, %g2
ld [%g1 + %g2], %g2
set trap, %g1
sub %g0, 1, %g4
rdpr %tstate, %g5
and %g5, TSTATE_CWP_MASK, %g5
ba,pt %xcc, tl0_utrap
ba,pt %xcc, tl0_skip_utrap
wrpr %g0, %g5, %cwp
END(fault_64bit_sn0)
@ -156,11 +151,6 @@ fault_fn1_common:
add %g1, 4, %g1
wrpr %g0, %g1, %tnpc
! convert hardware trap type to kernel trap type
set trap_conversion, %g1
sllx %g2, INT_SHIFT, %g2
ld [%g1 + %g2], %g2
set trap, %g1
mov 1, %g5
sllx %g5, CTX_OTHER_SHIFT, %g5
@ -173,10 +163,10 @@ fault_fn1_common:
mov KCONTEXT, %g5
mov MMU_CID_P, %g6
SET_MMU_CONTEXT(%g6, %g5)
membar #Sync
b tl0_ktrap
nop
ba,pt %xcc, tl0_ktrap
membar #Sync
END(fault_32bit_fn1)
ENTRY(fault_64bit_fn0)