From c7c0ca37673d8f1ae1c54dad1869101f566923f7 Mon Sep 17 00:00:00 2001 From: Heinrich Schuchardt Date: Sat, 13 May 2023 10:36:21 +0200 Subject: efi_loader: fix efi_dp_from_file() * When called from efi_dp_from_name() we miss to append the filename for non-block devices. * expand_media_path() could be simplified by using efi_dp_from_file to prepend the device path of the boot device. This can be avoided by passing a device path to efi_dp_from_file() instead of a block device descriptor and a partition number. Signed-off-by: Heinrich Schuchardt --- cmd/bootefi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'cmd/bootefi.c') diff --git a/cmd/bootefi.c b/cmd/bootefi.c index 8aa15a64c83..5c0afec1544 100644 --- a/cmd/bootefi.c +++ b/cmd/bootefi.c @@ -589,7 +589,7 @@ static efi_status_t bootefi_test_prepare if (!bootefi_device_path) return EFI_OUT_OF_RESOURCES; - bootefi_image_path = efi_dp_from_file(NULL, 0, path); + bootefi_image_path = efi_dp_from_file(NULL, path); if (!bootefi_image_path) { ret = EFI_OUT_OF_RESOURCES; goto failure; -- cgit v1.2.3