check for supervisor protection fault and issue a bus error
This commit is contained in:
@@ -380,7 +380,7 @@ reset_vector:
|
||||
jmp _rom_entry // no, cold start machine
|
||||
|
||||
access:
|
||||
move.w #0x2700,sr // disable interrupt
|
||||
move.w #0x2700,sr // disable interrupts
|
||||
move.l d0,-(sp) // ++ vr
|
||||
|
||||
move.w 4(sp),d0 // get format_status word from stack
|
||||
@@ -400,6 +400,12 @@ access_mmu:
|
||||
move.l MCF_MMU_MMUSR,d0 // did the last fault hit in TLB?
|
||||
btst #1,d0 // yes, it did. So we already mapped that page
|
||||
bne bus_error // and this must be a real bus error
|
||||
btst #5,d0 // supervisor protection fault?
|
||||
bne bus_error
|
||||
btst #4,d0 // read access fault?
|
||||
bne bus_error
|
||||
btst #3,d0 // write access fault?
|
||||
bne bus_error
|
||||
|
||||
move.l MCF_MMU_MMUAR,d0
|
||||
cmp.l #__FASTRAM_END,d0 // above max User RAM area?
|
||||
|
||||
Reference in New Issue
Block a user