[efi] Split device path functions out to efi_path.c

Signed-off-by: Michael Brown <mcb30@ipxe.org>
This commit is contained in:
Michael Brown
2020-10-16 14:12:56 +01:00
parent bcf858c56d
commit 2bf0fd39ca
14 changed files with 99 additions and 54 deletions

View File

@@ -26,7 +26,7 @@ FILE_LICENCE ( GPL2_OR_LATER );
#include <ipxe/rotate.h>
#include <ipxe/efi/efi.h>
#include <ipxe/efi/efi_driver.h>
#include <ipxe/efi/efi_utils.h>
#include <ipxe/efi/efi_path.h>
#include <ipxe/efi/Protocol/LoadedImage.h>
/** Image handle passed to entry point */
@@ -252,7 +252,7 @@ EFI_STATUS efi_init ( EFI_HANDLE image_handle,
* path, since the device handle itself may become invalidated
* when we load our own drivers.
*/
device_path_len = ( efi_devpath_len ( device_path ) +
device_path_len = ( efi_path_len ( device_path ) +
sizeof ( EFI_DEVICE_PATH_PROTOCOL ) );
if ( ( efirc = bs->AllocatePool ( EfiBootServicesData, device_path_len,
&device_path_copy ) ) != 0 ) {