31.3.3 Loading UEFI drivers

The following table lists the UEFI Shell commands that are available to load and start UEFI drivers.

Table 42-UEFI Shell commands for loading UEFI drivers

Command

Description

Load

Loads a UEFI driver from a file. UEFI driver files typically have an extension of .efi. The Load command has one important option, the -nc ("No Connect") option, for UEFI driver developers. When the Load command is used without the -nc option, then the loaded driver is automatically connected to any devices in the system that it is able to manage. This means that the UEFI driver's entry point is executed and then the UEFI Boot Service ConnectController() is called. If the UEFI driver produces the Driver Binding Protocol in the driver's entry point, then the ConnectController() call exercises the Supported() and Start() services of Driver Binding Protocol that was produced. If the -nc option is used with the Load command, then this automatic connect operation is not performed. Instead, only the UEFI driver's entry point is executed. When the -nc option is used, the UEFI Shell command connect can be used to connect the UEFI driver to any devices in the system that it is able to manage. The Load command can also take wild cards, so multiple UEFI drivers can be loaded at the same time. The code below shows the following examples of the Load command: Example 1: Loads and does not connect the UEFI driver image EfiDriver.efi. This example exercises only the UEFI driver's entry point: fs0:> Load -nc EfiDriver.efi Example 2: Loads and connects the UEFI driver image called EfiDriver.efi. This example exercises the UEFI driver's entry point and the Supported() and Start() functions of the Driver Binding Protocol: fs0:> Load EfiDriver.efi Example 3: Loads and connects all the UEFI drivers with an .efi extension from fs0:, exercising the UEFI driver entry points and their Supported() and Start() functions of the Driver Binding Protocol: `fs0:> Load .efi`

LoadPciRom

This command used to simulate the load of a PCI option ROM by the PCI bus driver. It also supports the -nc flag like the Load command, but takes the name of a PCI Option ROM file instead of an .efi file.