SCB Registers
162
SLAU723A – October 2017 – Revised October 2018
Copyright © 2017–2018, Texas Instruments Incorporated
Cortex-M4 Peripherals
2.5.12 FAULTSTAT Register (Offset = 0xD28) [reset = 0x0]
Configurable Fault Status (FAULTSTAT)
NOTE:
This register can only be accessed from privileged mode.
The FAULTSTAT register indicates the cause of a memory management fault, bus fault, or usage fault.
Each of these functions is assigned to a subregister as follows:
•
Usage Fault Status (UFAULTSTAT), bits 31:16
•
Bus Fault Status (BFAULTSTAT), bits 15:8
•
Memory Management Fault Status (MFAULTSTAT), bits 7:0
FAULTSTAT is byte accessible. FAULTSTAT or its subregisters can be accessed as follows:
•
The complete FAULTSTAT register, with a word access to offset 0xD28
•
The MFAULTSTAT, with a byte access to offset 0xD28
•
The MFAULTSTAT and BFAULTSTAT, with a halfword access to offset 0xD28
•
The BFAULTSTAT, with a byte access to offset 0xD29
•
The UFAULTSTAT, with a halfword access to offset 0xD2A
Bits are cleared by writing a 1 to them.
In a fault handler, the true faulting address can be determined by:
1. Read and save the Memory Management Fault Address (MMADDR) or Bus Fault Address
(FAULTADDR) value.
2. Read the MMARV bit in MFAULTSTAT, or the BFARV bit in BFAULTSTAT to determine if the
MMADDR or FAULTADDR contents are valid.
Software must follow this sequence because another higher priority exception might change the MMADDR
or FAULTADDR value. For example, if a higher priority handler preempts the current fault handler, the
other fault might change the MMADDR or FAULTADDR value.
FAULTSTAT is shown in
and described in
.
Return to
Figure 2-24. FAULTSTAT Register
31
30
29
28
27
26
25
24
RESERVED
DIV0
UNALIGN
R-0x0
R/W1C-0x0
R/W1C-0x0
23
22
21
20
19
18
17
16
RESERVED
NOCP
INVPC
INVSTAT
UNDEF
R-0x0
R/W1C-0x0
R/W1C-0x0
R/W1C-0x0
R/W1C-0x0
15
14
13
12
11
10
9
8
BFARV
RESERVED
BLSPERR
BSTKE
BUSTKE
IMPRE
PRECISE
IBUS
R/W1C-0x0
R-0x0
R/W1C-0x0
R/W1C-0x0
R/W1C-0x0
R/W1C-0x0
R/W1C-0x0
R/W1C-0x0
7
6
5
4
3
2
1
0
MMARV
RESERVED
MLSPERR
MSTKE
MUSTKE
RESERVED
DERR
IERR
R/W1C-0x0
R-0x0
R/W1C-0x0
R/W1C-0x0
R/W1C-0x0
R-0x0
R/W1C-0x0
R/W1C-0x0