Functions | |
VOID | PxeBcDisplayBootItem (IN UINT8 *Str, IN UINT8 Len) |
EFI_STATUS | PxeBcSelectBootPrompt (IN PXEBC_PRIVATE_DATA *Private) |
EFI_STATUS | PxeBcSelectBootMenu (IN PXEBC_PRIVATE_DATA *Private, OUT UINT16 *Type, IN BOOLEAN UseDefaultItem) |
EFI_STATUS | PxeBcDhcp4BootInfo (IN OUT PXEBC_PRIVATE_DATA *Private, OUT UINT64 *BufferSize) |
EFI_STATUS | PxeBcDhcp6BootInfo (IN OUT PXEBC_PRIVATE_DATA *Private, OUT UINT64 *BufferSize) |
EFI_STATUS | PxeBcExtractDiscoverInfo (IN PXEBC_PRIVATE_DATA *Private, IN UINT16 Type, IN OUT EFI_PXE_BASE_CODE_DISCOVER_INFO **DiscoverInfo, OUT PXEBC_BOOT_SVR_ENTRY **BootEntry, OUT EFI_PXE_BASE_CODE_SRVLIST **SrvList) |
EFI_STATUS | PxeBcDiscoverBootServer (IN PXEBC_PRIVATE_DATA *Private, IN UINT16 Type, IN UINT16 *Layer, IN BOOLEAN UseBis, IN EFI_IP_ADDRESS *DestIp, IN UINT16 IpCount, IN EFI_PXE_BASE_CODE_SRVLIST *SrvList) |
EFI_STATUS | PxeBcDiscoverBootFile (IN OUT PXEBC_PRIVATE_DATA *Private, OUT UINT64 *BufferSize) |
EFI_STATUS | PxeBcInstallCallback (IN OUT PXEBC_PRIVATE_DATA *Private, OUT BOOLEAN *NewMakeCallback) |
VOID | PxeBcUninstallCallback (IN PXEBC_PRIVATE_DATA *Private, IN BOOLEAN NewMakeCallback) |
EFI_STATUS | PxeBcReadBootFileList (IN PXEBC_PRIVATE_DATA *Private, IN OUT UINT64 *BufferSize, IN VOID *Buffer) |
EFI_STATUS | PxeBcLoadBootFile (IN PXEBC_PRIVATE_DATA *Private, IN OUT UINTN *BufferSize, IN VOID *Buffer) |
Copyright (c) 2009 - 2014, Intel Corporation. All rights reserved.
This program and the accompanying materials are licensed and made available under the terms and conditions of the BSD License which accompanies this distribution. The full text of the license may be found at http://opensource.org/licenses/bsd-license.php.
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
EFI_STATUS PxeBcDhcp4BootInfo | ( | IN OUT PXEBC_PRIVATE_DATA * | Private, | |
OUT UINT64 * | BufferSize | |||
) |
Parse out the boot information from the last Dhcp4 reply packet.
[in,out] | Private | Pointer to PxeBc private data. |
[out] | BufferSize | Size of the boot file to be downloaded. |
EFI_SUCCESS | Successfully parsed out all the boot information. | |
Others | Failed to parse out the boot information. |
References PXEBC_VENDOR_OPTION::BitMap, PXEBC_VENDOR_OPTION::BootSvr, PXEBC_VENDOR_OPTION::BootSvrLen, PXEBC_VENDOR_OPTION::DiscoverCtrl, PXEBC_BOOT_SVR_ENTRY::IpAddr, PXEBC_BOOT_SVR_ENTRY::IpCnt, IS_DISABLE_PROMPT_MENU, IS_VALID_BOOT_SERVERS, PXEBC_DHCP4_PACKET::Offer, PXEBC_DHCP4_PACKET_CACHE::OptList, PXEBC_DHCP4_PACKET_CACHE::Packet, PXEBC_DHCP4_TAG_INDEX_BOOTFILE, PXEBC_DHCP4_TAG_INDEX_BOOTFILE_LEN, PXEBC_DHCP4_TAG_INDEX_SERVER_ID, PxeBcShowIp4Addr(), and PXEBC_DHCP4_PACKET_CACHE::VendorOpt.
Referenced by PxeBcDiscoverBootFile().
EFI_STATUS PxeBcDhcp6BootInfo | ( | IN OUT PXEBC_PRIVATE_DATA * | Private, | |
OUT UINT64 * | BufferSize | |||
) |
Parse out the boot information from the last Dhcp6 reply packet.
[in,out] | Private | Pointer to PxeBc private data. |
[out] | BufferSize | Size of the boot file to be downloaded. |
EFI_SUCCESS | Successfully parsed out all the boot information. | |
EFI_BUFFER_TOO_SMALL | ||
Others | Failed to parse out the boot information. |
References PXEBC_DHCP6_PACKET_CACHE::OptList, PXEBC_DHCP6_IDX_BOOT_FILE_PARAM, PXEBC_DHCP6_IDX_BOOT_FILE_URL, PxeBcExtractBootFileParam(), PxeBcExtractBootFileUrl(), PxeBcSetIp6Address(), and PxeBcShowIp6Addr().
Referenced by PxeBcDiscoverBootFile().
EFI_STATUS PxeBcDiscoverBootFile | ( | IN OUT PXEBC_PRIVATE_DATA * | Private, | |
OUT UINT64 * | BufferSize | |||
) |
Discover all the boot information for boot file.
[in,out] | Private | Pointer to PxeBc private data. |
[out] | BufferSize | Size of the boot file to be downloaded. |
EFI_SUCCESS | Successfully obtained all the boot information . | |
EFI_BUFFER_TOO_SMALL | The buffer size is not enough for boot file. | |
EFI_ABORTED | User cancel current operation. | |
Others | Failed to parse out the boot information. |
References PxeBcDhcp4BootInfo(), PxeBcDhcp6BootInfo(), PxeBcSelectBootMenu(), and PxeBcSelectBootPrompt().
Referenced by PxeBcLoadBootFile().
EFI_STATUS PxeBcDiscoverBootServer | ( | IN PXEBC_PRIVATE_DATA * | Private, | |
IN UINT16 | Type, | |||
IN UINT16 * | Layer, | |||
IN BOOLEAN | UseBis, | |||
IN EFI_IP_ADDRESS * | DestIp, | |||
IN UINT16 | IpCount, | |||
IN EFI_PXE_BASE_CODE_SRVLIST * | SrvList | |||
) |
Build the discover packet and send out for boot server.
[in] | Private | Pointer to PxeBc private data. |
[in] | Type | PxeBc option boot item type. |
[in] | Layer | Pointer to option boot item layer. |
[in] | UseBis | Use BIS or not. |
[in] | DestIp | Pointer to the destination address. |
[in] | IpCount | The count of the server address. |
[in] | SrvList | Pointer to the server address list. |
EFI_SUCCESS | Successfully discovered boot file. | |
EFI_OUT_OF_RESOURCES | Failed to allocate resource. | |
EFI_NOT_FOUND | Can't get the PXE reply packet. | |
Others | Failed to discover boot file. |
References PxeBcDhcp4Discover(), and PxeBcDhcp6Discover().
Referenced by EfiPxeBcDiscover().
VOID PxeBcDisplayBootItem | ( | IN UINT8 * | Str, | |
IN UINT8 | Len | |||
) |
Display the string of the boot item.
If the length of the boot item string beyond 70 Char, just display 70 Char.
[in] | Str | The pointer to the string. |
[in] | Len | The length of the string. |
References PXEBC_DISPLAY_MAX_LINE.
Referenced by PxeBcSelectBootMenu(), and PxeBcSelectBootPrompt().
EFI_STATUS PxeBcExtractDiscoverInfo | ( | IN PXEBC_PRIVATE_DATA * | Private, | |
IN UINT16 | Type, | |||
IN OUT EFI_PXE_BASE_CODE_DISCOVER_INFO ** | DiscoverInfo, | |||
OUT PXEBC_BOOT_SVR_ENTRY ** | BootEntry, | |||
OUT EFI_PXE_BASE_CODE_SRVLIST ** | SrvList | |||
) |
Extract the discover information and boot server entry from the cached packets if unspecified.
[in] | Private | Pointer to PxeBc private data. |
[in] | Type | The type of bootstrap to perform. |
[in,out] | DiscoverInfo | Pointer to EFI_PXE_BASE_CODE_DISCOVER_INFO. |
[out] | BootEntry | Pointer to PXEBC_BOOT_SVR_ENTRY. |
[out] | SrvList | Pointer to EFI_PXE_BASE_CODE_SRVLIST. |
EFI_SUCCESS | Successfully extracted the information. | |
EFI_DEVICE_ERROR | Failed to extract the information. |
References PXEBC_VENDOR_OPTION::BitMap, PXEBC_VENDOR_OPTION::BootSvr, PXEBC_VENDOR_OPTION::BootSvrLen, PXEBC_VENDOR_OPTION::DiscoverCtrl, PXEBC_VENDOR_OPTION::DiscoverMcastIp, GET_NEXT_BOOT_SVR_ENTRY, PXEBC_BOOT_SVR_ENTRY::IpAddr, PXEBC_BOOT_SVR_ENTRY::IpCnt, IS_DISABLE_BCAST_DISCOVER, IS_DISABLE_MCAST_DISCOVER, IS_ENABLE_USE_SERVER_LIST, IS_VALID_BOOT_SERVERS, IS_VALID_DISCOVER_VENDOR_OPTION, PXEBC_BOOT_SVR_ENTRY::Type, and PXEBC_DHCP4_PACKET_CACHE::VendorOpt.
Referenced by EfiPxeBcDiscover().
EFI_STATUS PxeBcInstallCallback | ( | IN OUT PXEBC_PRIVATE_DATA * | Private, | |
OUT BOOLEAN * | NewMakeCallback | |||
) |
Install PxeBaseCodeCallbackProtocol if not installed before.
[in,out] | Private | Pointer to PxeBc private data. |
[out] | NewMakeCallback | If TRUE, it is a new callback. Otherwise, it is not new callback. |
EFI_SUCCESS | PxeBaseCodeCallbackProtocol installed succesfully. | |
Others | Failed to install PxeBaseCodeCallbackProtocol. |
References gPxeBcCallBackTemplate.
Referenced by PxeBcLoadBootFile().
EFI_STATUS PxeBcLoadBootFile | ( | IN PXEBC_PRIVATE_DATA * | Private, | |
IN OUT UINTN * | BufferSize, | |||
IN VOID * | Buffer | |||
) |
Load boot file into user buffer.
[in] | Private | Pointer to PxeBc private data. |
[in,out] | BufferSize | Size of user buffer for input; required buffer size for output. |
[in] | Buffer | Pointer to user buffer. |
EFI_SUCCESS | Get all the boot information successfully. | |
EFI_BUFFER_TOO_SMALL | The buffer size is not enough for boot file. | |
EFI_ABORTED | User cancelled the current operation. | |
Others | Failed to parse out the boot information. |
References PXEBC_IS_SIZE_OVERFLOWED, PxeBcDiscoverBootFile(), PxeBcInstallCallback(), PxeBcReadBootFileList(), and PxeBcUninstallCallback().
Referenced by EfiPxeLoadFile().
EFI_STATUS PxeBcReadBootFileList | ( | IN PXEBC_PRIVATE_DATA * | Private, | |
IN OUT UINT64 * | BufferSize, | |||
IN VOID * | Buffer | |||
) |
Download one of boot file in the list, and it's special for IPv6.
[in] | Private | Pointer to PxeBc private data. |
[in,out] | BufferSize | Size of user buffer for input; required buffer size for output. |
[in] | Buffer | Pointer to user buffer. |
EFI_SUCCESS | Read one of boot file in the list successfully. | |
EFI_BUFFER_TOO_SMALL | The buffer size is not enough for boot file. | |
EFI_NOT_FOUND | There is no proper boot file available. | |
Others | Failed to download boot file in the list. |
Referenced by PxeBcLoadBootFile().
EFI_STATUS PxeBcSelectBootMenu | ( | IN PXEBC_PRIVATE_DATA * | Private, | |
OUT UINT16 * | Type, | |||
IN BOOLEAN | UseDefaultItem | |||
) |
Select the boot menu by user's input.
[in] | Private | Pointer to PxeBc private data. |
[out] | Type | The type of the menu. |
[in] | UseDefaultItem | Use default item or not. |
EFI_ABORTED | User cancel operation. | |
EFI_SUCCESS | Select the boot menu success. | |
EFI_NOT_READY | Read the input key from the keybroad has not finish. |
References PXEBC_VENDOR_OPTION::BitMap, PXEBC_VENDOR_OPTION::BootMenu, PXEBC_VENDOR_OPTION::BootMenuLen, CTRL, PXEBC_BOOT_MENU_ENTRY::DescLen, PXEBC_DHCP_PACKET_CACHE::Dhcp4, PXEBC_DHCP_PACKET_CACHE::Dhcp6, IS_VALID_BOOT_MENU, PXEBC_DHCP4_PACKET_CACHE::OfferType, PXEBC_DHCP6_PACKET_CACHE::OfferType, PXEBC_DISPLAY_MAX_LINE, PXEBC_MENU_MAX_NUM, PxeBcDisplayBootItem(), PxeOfferTypeDhcpPxe10, PxeOfferTypeProxyPxe10, and PXEBC_DHCP4_PACKET_CACHE::VendorOpt.
Referenced by PxeBcDiscoverBootFile().
EFI_STATUS PxeBcSelectBootPrompt | ( | IN PXEBC_PRIVATE_DATA * | Private | ) |
Select and maintain the boot prompt if needed.
[in] | Private | Pointer to PxeBc private data. |
EFI_SUCCESS | Selected boot prompt done. | |
EFI_TIMEOUT | Selected boot prompt timed out. | |
EFI_NOT_FOUND | The proxy offer is not Pxe10. | |
EFI_ABORTED | User cancelled the operation. | |
EFI_NOT_READY | Reading the input key from the keyboard has not finish. |
References PXEBC_VENDOR_OPTION::BitMap, CTRL, PXEBC_DHCP_PACKET_CACHE::Dhcp4, PXEBC_DHCP_PACKET_CACHE::Dhcp6, PXEBC_VENDOR_OPTION::DiscoverCtrl, IS_DISABLE_PROMPT_MENU, IS_VALID_BOOT_PROMPT, PXEBC_VENDOR_OPTION::MenuPrompt, PXEBC_VENDOR_OPTION::MenuPromptLen, PXEBC_DHCP4_PACKET_CACHE::OfferType, PXEBC_DHCP6_PACKET_CACHE::OfferType, PXEBC_DHCP4_PACKET_CACHE::OptList, PXEBC_MENU_PROMPT::Prompt, PXEBC_DHCP4_TAG_INDEX_BOOTFILE, PxeBcDisplayBootItem(), PxeOfferTypeDhcpPxe10, PxeOfferTypeProxyPxe10, PXEBC_MENU_PROMPT::Timeout, and PXEBC_DHCP4_PACKET_CACHE::VendorOpt.
Referenced by PxeBcDiscoverBootFile().
VOID PxeBcUninstallCallback | ( | IN PXEBC_PRIVATE_DATA * | Private, | |
IN BOOLEAN | NewMakeCallback | |||
) |
Uninstall PxeBaseCodeCallbackProtocol.
[in] | Private | Pointer to PxeBc private data. |
[in] | NewMakeCallback | If TRUE, it is a new callback. Otherwise, it is not new callback. |
Referenced by PxeBcLoadBootFile().