Abort Model - ARM Cortex-M3 Technical Reference Manual

R2p0
Hide thumbs Also See for Cortex-M3:
Table of Contents

Advertisement

5.12

Abort model

5.12.1
Hard Fault
5.12.2
Local faults and escalation
ARM DDI 0337G
Unrestricted Access
Four events can generate a fault:
An instruction fetch or vector table load bus error.
A data access bus error.
Internally-detected error such as an undefined instruction or an attempt to change
state with a BX instruction. Fault status registers in the NVIC indicate the causes
of the faults.
MPU fault because of privilege violation or unmanaged region.
There are two kinds of fault handler:
the fixed-priority Hard Fault
the settable-priority local faults.
Only Reset and NMI can pre-empt the fixed priority Hard Fault. A Hard Fault can
pre-empt any other exception other than Reset NMI or another Hard Fault.
Note
Code that uses FAULTMASK acts as a Hard Fault and so follows the same rules as a
Hard Fault.
Secondary bus faults do not escalate because a pre-empting fault of the same type
cannot pre-empt itself. This means that if a corrupted stack causes a fault, the fault
handler still executes even though the stack pushes for the handler failed. The fault
handler can operate, but the stack contents are corrupted.
Local faults are categorized according to their cause. See Table 5-10 on page 5-28.
When enabled, local fault handlers process all normal faults. However, a local fault
escalates to a Hard Fault when:
A local fault handler causes the same kind of fault as the one it is servicing.
A local fault handler causes a fault with the same or higher priority.
An exception handler causes a fault with the same or higher priority.
The local fault is not enabled.
Copyright © 2005-2008 ARM Limited. All rights reserved.
Non-Confidential
Exceptions
5-27

Advertisement

Table of Contents
loading

Table of Contents