summaryrefslogtreecommitdiff
path: root/fallback.c
diff options
context:
space:
mode:
authorPeter Jones <pjones@redhat.com>2013-05-14 13:10:34 -0400
committerPeter Jones <pjones@redhat.com>2013-05-14 13:10:52 -0400
commita41306e8f49dae129b1cc0479e5ffa311c2797f8 (patch)
tree417c5053f7389fbec410dce1886faf5636f941a2 /fallback.c
parent3fa9a53425a947f10cbeed35ce2c033d7cf4985e (diff)
downloadefi-boot-shim-a41306e8f49dae129b1cc0479e5ffa311c2797f8.tar.gz
efi-boot-shim-a41306e8f49dae129b1cc0479e5ffa311c2797f8.zip
Pass parameters correctly when booting.
Signed-off-by: Peter Jones <pjones@redhat.com>
Diffstat (limited to 'fallback.c')
-rw-r--r--fallback.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/fallback.c b/fallback.c
index 387c84a8..cf1ebe46 100644
--- a/fallback.c
+++ b/fallback.c
@@ -626,6 +626,14 @@ try_start_first_option(EFI_HANDLE parent_image_handle)
uefi_call_wrapper(BS->Stall, 1, 2000000);
return rc;
}
+
+ EFI_LOADED_IMAGE *image;
+ rc = uefi_call_wrapper(BS->HandleProtocol, 3, image_handle, &LoadedImageProtocol, (void *)&image);
+ if (!EFI_ERROR(rc)) {
+ image->LoadOptions = first_new_option_args;
+ image->LoadOptionsSize = first_new_option_size;
+ }
+
rc = uefi_call_wrapper(BS->StartImage, 3, image_handle, NULL, NULL);
if (EFI_ERROR(rc)) {
Print(L"StartImage failed: %d\n", rc);