You copied the Doc URL to your clipboard.

3.3.13. c5, Data Fault Status Register, DFSR

The purpose of the Data Fault Status Register (DFSR) is to hold the source of the last data fault. The Data Fault Status Register indicates the domain and type of access being attempted when an abort occurred.

The Data Fault Status Register is:

  • in CP15 c5

  • a 32-bit read/write register

  • accessible in privileged mode only.

Figure 3.33 shows the arrangement of bits in the register.

Figure 3.33. Data Fault Status Register format

Figure 3.33. Data Fault Status Register format

Table 3.61shows the bit functions of the Data Fault Status Register.

Table 3.61. Data Fault Status Register bits

Bit range

Field nameFunction

[31:12]

-

UNP/SBZ.

[11]

RW

Not Read/Write.

Indicates which type of access caused the abort:

0 = Read

1 = Write

When a CP15 cache maintenance operation fault causes an abort, the value returned is 1.

[10]

Status[4]

Part of the Status field, see Bits[3:0] in this table.

[9:8]

-

Always read as 0. Writes to these bits are ignored.

[7:4]

Domain

Specifies which of the 16 domains (D15-D0) was being accessed when a data fault occurred. Possible values are 0 to 15. Reset value is 0.

[3:0]

Status[3:0]

Type of fault generated. See Table 3.62 for a list of the fault encodings, and Fault status and address for full details of Domain and FAR validity.


The fault status field bit encodings are shown in Table 3.62.

Table 3.62. DFSR fault status encoding
Status[4:0][a]Fault source
b00000No function, reset value
b00001Alignment fault
b00010Debug event fault
b00011Access Flag fault on Section
b00100Cache maintenance operation fault[b]
b00101Translation fault on Section
b00110Access Flag fault on Page
b00111Translation fault on Page
b01000Precise External Abort
b01001Domain fault on Section
b01010No function
b01011Domain fault on Page
b01100External abort on translation, first level
b01101Permission fault on Section
b01110External abort on translation, second level
b01111Permission fault on Page
b100xxNo function
b1010xNo function
b10110Imprecise External Abort
b10111No function
b11xxxNo function

[a] Bits[10,3:0] of the DFSR register.

[b] Can only occur on the Data side. On the IFSR, the corresponding encoding (b0100) has no function.


Accessing the Data Fault Status Register

Table 3.63 shows the results of attempted accesses to the Data Fault Status Register for each mode.

Table 3.63. Results of accesses to the Data Fault Status Register
Privileged readPrivileged writeUser read or write
Data readData writeUndefined Instruction exception

To access the Data Fault Status Register you read or write CP15 with:

  • Opcode_1 set to 0

  • CRn set to c5

  • CRm set to c0

  • Opcode_2 set to 0.

For example:

MRC p15, 0, <Rd>, c5, c0, 0            ; Read Data Fault Status Register
MCR p15, 0, <Rd>, c5, c0, 0            ; Write Data Fault Status Register

Reading CP15 c5 with Opcode_2 set to 0 returns the value of the Data Fault Status Register.

Writing CP15 c5 with Opcode_2 set to 0 sets the Data Fault Status Register to the value of the data written, ignoring any value written to bits[9:8]. This is useful for a debugger to restore the value of the Data Fault Status Register.