diff options
| author | Simon Rettberg | 2021-10-05 16:07:52 +0200 |
|---|---|---|
| committer | Simon Rettberg | 2021-10-05 16:07:52 +0200 |
| commit | 33d46d7beb452ce022709e1e2c302777cbab7f46 (patch) | |
| tree | 2557c318c869b362317b6dd6b7a3d7d3fe4069b6 /src/interface/efi/efi_block.c | |
| parent | [efi] local: Allow loading from any volume by using file://*/... (diff) | |
| download | ipxe-33d46d7beb452ce022709e1e2c302777cbab7f46.tar.gz ipxe-33d46d7beb452ce022709e1e2c302777cbab7f46.tar.xz ipxe-33d46d7beb452ce022709e1e2c302777cbab7f46.zip | |
Local UEFI disk boot support
By Aaron Young:
https://lists.ipxe.org/pipermail/ipxe-devel/2019-February/006504.html
Diffstat (limited to 'src/interface/efi/efi_block.c')
| -rw-r--r-- | src/interface/efi/efi_block.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/interface/efi/efi_block.c b/src/interface/efi/efi_block.c index 74cf7c0c0..18b1504e7 100644 --- a/src/interface/efi/efi_block.c +++ b/src/interface/efi/efi_block.c @@ -57,6 +57,7 @@ FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL ); #include <ipxe/efi/efi_path.h> #include <ipxe/efi/efi_null.h> #include <ipxe/efi/efi_block.h> +#include <usr/efiboot.h> /** ACPI table protocol protocol */ static EFI_ACPI_TABLE_PROTOCOL *acpi; @@ -632,7 +633,12 @@ static int efi_block_boot ( unsigned int drive, const char *filename ) { sandev = sandev_find ( drive ); if ( ! sandev ) { DBG ( "EFIBLK cannot find drive %#02x\n", drive ); - rc = -ENODEV; + DBG ( "EFIBLK attempting local boot for drive %#02x, " + "filename=%s\n", drive, filename ); + rc = efi_boot_local( drive, filename ); + if (rc) + rc = -ENODEV; + goto err_sandev_find; } |
