Chapter 5 Detailed Applications
- 79 -
5.5 Regarding Interrupts

5.5.1 Types of Interrupt Handlers

MR308's interrupt handlers consist of kernel(OS-dependent) interrupt handlers and non-kernel
(OS-independent) interrupt handlers.
The following shows the definition of each type of interrupt handler.
Kernel(OS-dependent) interrupt handler
The kernel(OS-dependent) interrupt handler is defined as one that satisfies one of the following two
conditions:
Interrupt handlers issuing a service call
Interrupt handlers including multiple interrupt handlers issuing a service call
The kernel(OS-dependent) interrupt handler's IPL value must be below the kernel mask level (OS in-
terrupt disable level = system.IPL ). IPL = 0 to system.IPL56
Non-kernel(OS-independent) interrupt handler
The non-kernel(OS-independent) interrupt handler is defined as one that satisfies both of the following
two conditions:
Interrupt handlers not issuing a service call
Interrupt handlers that do not have multiple interrupts of interrupt handlers issuing a service call
(system clock interrupt handler)
The non-kernel(OS-independent) interrupt handler's IPL value must be between (system.IPL + 1) to 7.
Namely, the non-kernel(OS-independent) interrupt handler's IPL value cannot be set below the ker-
nel(OS-independent) interrupt disable level.
Figure 5.11 shows the relationship between the non-kernel(OS-independent) interrupt handlers and ker-
nel(OS-dependent) interrupt handlers where the kernel mask level(OS interrupt disable level) is set to 3.
High
Low

0 1 2 3 4 5 6 7

Kernel
(OS-dependent)
Interrupt handler
Non-kernel
(OS-independent)
Interrupt handler
Kernel mask level
(OS Interrupt disable level)
Figure 5.11 Interrupt handler IPLs

5.5.2 The Use of Non-maskable Interrupt

An NMI interrupt and Watchdog Timer interrupt have to use be a non-kernel(OS independent) interrupt handler.
If they are a kernel(OS dependent) interrupt handler, the program will not work normally.
56 system.IPL is set by the configuration file.