Extensible Firmware Interface Specification
416 12/12/00 Version 1.02
G.4 UNDI Commands
All 32/64-bit UNDI commands use the same basic command format, the CDB (Command
Descriptor Block). CDB fields that are not used by a particular command must be initialized to
zero by the application/driver that is issuing the command.
All UNDI implementations must set the command completion status
(PXE_STATFLAGS_COMMAND_COMPLETE) after command execution completes. Applications
and drivers must not alter or rely on the contents of any of the CDB, CPB or DB fields until the
command completion status is set.
All commands return status codes for invalid CDB contents and, if used, invalid CPB contents.
Commands with invalid parameters will not execute. Fix the error and submit the command again.
The figure below describes the different UNDI states (Stopped, Started and Initialized), shows the
transitions between the states and which UNDI commands are valid in each state.
Stopped
Initialized
Started
StartStop
Shutdown Initialize
Valid Commands
Get State
Start
Valid Commands
Get State
Get Init Info
Reset
Shutdown
Get Runtime Info
Set Runtime Info
Get Status
Fill Header
Transmit
Receive
MCast IP To MAC
Valid Commands
Get State
Stop
Get Init Info
Initialize
MCast IP To MAC
Figure G-6. UNDI States, Transitions & Valid Commands
Note: Additional requirements for S/W UNDI implementations: CPU register contents must be
unchanged by S/W UNDI command execution (the application/driver does not have to save CPU
registers when calling S/W UNDI). CPU arithmetic flags are undefined (application/driver must
save CPU arithmetic flags if needed). Application/driver must remove CDB address from stack
after control returns from S/W UNDI.
When executing linked commands, command execution will stop at the end of the CDB list (when
the PXE_CONTROL_LINK bit is not set) or when a command returns an error status code.