diff options
author | Masahisa Kojima <masahisa.kojima@linaro.org> | 2023-12-04 13:30:14 +0900 |
---|---|---|
committer | Heinrich Schuchardt <heinrich.schuchardt@canonical.com> | 2024-04-20 08:21:59 +0200 |
commit | 05bf7adf87b02feb593fb553e377cd196a4598f0 (patch) | |
tree | 5de20ee2d086abaa3160dbb808e63119b6688e1d /lib/efi_loader/efi_helper.c | |
parent | 2608015921f61425f09e3a413f22be6c155a13a7 (diff) |
efi_loader: use event callback for initrd deregistration
Currently efi_initrd_deregister() is called in bootefi.c
when the image started from bootefi command returns.
Since efi_guid_event_group_return_to_efibootmgr event is
implemented, so let's use this event for invoking
initrd deregistration.
Signed-off-by: Masahisa Kojima <masahisa.kojima@linaro.org>
Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Tested-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
Diffstat (limited to 'lib/efi_loader/efi_helper.c')
-rw-r--r-- | lib/efi_loader/efi_helper.c | 5 |
1 files changed, 0 insertions, 5 deletions
diff --git a/lib/efi_loader/efi_helper.c b/lib/efi_loader/efi_helper.c index 58761fae784..6918fd5e48a 100644 --- a/lib/efi_loader/efi_helper.c +++ b/lib/efi_loader/efi_helper.c @@ -549,11 +549,6 @@ efi_status_t do_bootefi_exec(efi_handle_t handle, void *load_options) out: free(load_options); - if (IS_ENABLED(CONFIG_EFI_LOAD_FILE2_INITRD)) { - if (efi_initrd_deregister() != EFI_SUCCESS) - log_err("Failed to remove loadfile2 for initrd\n"); - } - /* Notify EFI_EVENT_GROUP_RETURN_TO_EFIBOOTMGR event group. */ list_for_each_entry(evt, &efi_events, link) { if (evt->group && |