Development Support
MOTOROLA
MPC801 USER’S MANUAL
18-27
18
The processor enters into the debug mode state when at least one of the bits in the ICR is
set, the corresponding bit in the DER is enabled, and debug mode is enabled. When debug
mode is enabled and an enabled event occurs, the processor waits until its pipeline is empty
and then starts fetching the next instructions from the development port. For information on
the exact value of SRR0 and SRR1, refer to
Section 7.3.7.3 Definitions
. When the
processor is in debug mode, the freeze indication is asserted, thus allowing any properly
programmed peripheral to stop. The fact that the core is in debug mode is also broadcasted
to the external world using the value b’11’ on the VFLS pins. The freeze signal can be
asserted by the software when debug mode is disabled. The development port should read
the value of the ICR to find out what causes debug mode entry. Reading the ICR clears all
of its bits.
18.3.2.3 CHECKSTOP STATE AND DEBUG MODE.
The core enters checkstop state if
the machine check interrupt is disabled (MSR
ME
=0) and a machine check interrupt is
detected. However, if a machine check interrupt is detected when MSR
ME
=0, debug mode
is enabled, the checkstop enable bit in the DER is set, and the core enters debug mode
rather then the checkstop state. The various actions taken by the core when a machine
check interrupt is detected are provided in the following table.
18.3.2.4 SAVING THE MACHINE STATE IN DEBUG MODE.
If entering debug mode is
the result of a load/store-type exception, the data address register (DER) and data/storage
interrupt status register (DSISR) contain critical information. These two registers must be
saved before any other operation is performed. Failing to save these registers can result in
information loss if another load/store-type exception occurs inside the development
software. Since exceptions are treated differently in debug mode, there is no need to save
the save/restore registers 0 and 1 (SRR0 and SRR1).
Table 18-7. Checkstop State and Debug Mode
MSR
ME
DEBUG
MODE
ENABLE
CHSTPE
2
MCIE
2
ACTION PERFORMED BY THE CORE
WHEN A MACHINE
CHECK INTERRUPT IS DETECTED
INTERRUPT
CAUSE
REGISTER
VALUE
0
0
X
X
Enter Checkstop State
0x20000000
1
0
X
X
Branch to the Machine Check Interrupt
0x10000000
0
1
0
X
Enter Checkstop State
0x20000000
0
1
1
X
Enter Debug Mode
0x20000000
1
1
X
0
Branch to the Machine Check Interrupt
0x10000000
1
1
X
1
Enter Debug Mode
0x10000000
NOTES: 1.
The checkstop enable bit of the DER.
2.
The machine check interrupt enable bit of the DER.