CHAPTER 7 INTERRUPTION/EXCEPTION PROCESSING FUNCTION
295
User’s Manual U14359EJ4V0UM
7.6
Multiple Interrupt Servicing Control
Multiple interrupt servicing control is a process by which an interrupt request that is currently being serviced can
be interrupted during servicing if there is an interrupt request with a higher priority level, and the higher priority
interrupt request is acknowledged and serviced first.
If there is an interrupt request with a lower priority level than the interrupt request currently being serviced, that
interrupt request is held pending.
Multiple interrupt servicing control of maskable interrupts is executed when interrupts are enabled (ID = 0). Thus,
to execute multiple interrupts, it is necessary to set the interrupt enabled state (ID = 0) even for an interrupt service
routine.
If maskable interrupts are enabled or a software exception is generated in a maskable interrupt or software
exception service program, it is necessary to save EIPC and EIPSW.
This is accomplished by the following procedure.
(1) Acknowledgement of maskable interrupts in service program
Service program of maskable interrupt or exception
...
...
•
EIPC saved to memory or register
•
EIPSW saved to memory or register
•
EI instruction (interrupt acknowledgement enabled)
...
...
←
Maskable interrupt acknowledgement
...
...
•
DI instruction (interrupt acknowledgement disabled)
•
Saved value restored to EIPSW
•
Saved value restored to EIPC
•
RETI instruction