27.2 Load File Protocol Implementation

The implementation of the Load File Protocol is typically found in the file LoadFile.c. Appendix A contains a template for a LoadFile.c file for a UEFI Driver. The list of tasks to implement the Load File Protocol is as follows:
  • Add global variable for the EFI_LOAD_FILE_PROTOCOL instance to LoadFile.c.
  • Implement the LoadFile() service in LoadFile.c.
The example below shows the protocol interface structure for the Load File Protocol for reference. This protocol is composed of a single service called LoadFile(). This service is typically used by a UEFI Boot Manager to boot a UEFI OS Loader or other UEFI Application from a device that does not directly or indirectly support the Simple File System Protocol.

Example 242-Load File Protocol

extern EFI_GUID gEfiLoadFileProtocolGuid;