Extensible Firmware Interface Specification
28 12/12/00 Version 1.02
Table 3-2. TPL Usage (continued)
Task Priority Level Usage
(Firmware Interrupts) This level is internal to the firmware. It is the level at which internal interrupts
occur. Code running at this level interrupts code running at the
TPL_NOTIFY level (or lower levels). If the interrupt requires extended time
to complete, firmware signals another event (or events) to perform the longer
term operations so that other interrupts can occur.
TPL_HIGH_LEVEL Interrupts code executing below TPL_HIGH_LEVEL. This is the highest
priority level. It is not interruptable (interrupts are disabled) and is used
sparingly by firmware to synchronize operations that need to be accessible
from any priority level. For example, it must be possible to signal events while
executing at any priority level. Therefore, firmware manipulates the internal
event structure while at this priority level.
Executing code can temporarily raise its priority level by calling the RaiseTPL() function.
Doing this masks event notifications from code running at equal or lower priority levels until the
RestoreTPL() function is called to reduce the priority to a level below that of the pending event
notifications. There are restrictions on the TPL levels at which many EFI service functions and
protocol interface functions can execute. Table 3-3 summarizes the restrictions.
Table 3-3. TPL Restrictions
Name Restriction Task Priority Level
Memory Allocation Services <= TPL_NOTIFY
Variable Services <= TPL_CALLBACK
ExitBootServices() = TPL_APPLICATION
LoadImage() <= TPL_CALLBACK
WaitForEvent() = TPL_APPLICATION
SignalEvent() <= TPL_HIGH_LEVEL
Event Notification Levels >
<=
TPL_APPLICATION
TPL_HIGH_LEVEL
Protocol Interface Functions <= TPL_NOTIIFY
Block I/O Protocol <= TPL_CALLBACK
Disk I/O Protocol <= TPL_CALLBACK
Simple File System Protocol <= TPL_CALLBACK
Simple Input Protocol <= TPL_APPLICATION
Simple Text Output Protocol <= TPL_NOTIFY
Serial I/O Protocol <= TPL_CALLBACK
PXE Base Code Protocol <= TPL_CALLBACK
Simple Network Protocol <= TPL_CALLBACK