The EFI selftest should match executing a real EFI binary
as closely as possible.
Use do_bootefi_exec() to enter the EFI selftest.
Acked-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
if (ret != EFI_SUCCESS)
return ret;
+ (*image_objp)->auth_status = EFI_IMAGE_AUTH_PASSED;
+ (*image_objp)->entry = efi_selftest;
+
/* Transfer environment variable as load options */
return efi_env_set_load_options((efi_handle_t)*image_objp,
load_options_path,
return CMD_RET_FAILURE;
/* Execute the test */
- ret = EFI_CALL(efi_selftest(&image_obj->header, &systab));
- free(loaded_image_info->load_options);
+ ret = do_bootefi_exec(&image_obj->header,
+ loaded_image_info->load_options);
efi_free_pool(test_device_path);
efi_free_pool(test_image_path);
if (ret != EFI_SUCCESS)