提交 b0b1449b 编写于 作者: M Masami Hiramatsu 提交者: Heinrich Schuchardt

efi_loader: Fix to set bootdev_root correctly if bootdev found

Fix find_boot_device() to set bootdev_root if it finds the
bootdev from BootNext. Currently it sets the bootdev_root only
when it finds bootdev from BootOrder.

Fixes: c74cd8bd ("efi_loader: capsule: add capsule_on_disk support")
Signed-off-by: NMasami Hiramatsu <masami.hiramatsu@linaro.org>
Accked-by: NIlias Apalodimas <ilias.apalodimas@linaro.org>
Reviewed-by: NHeinrich Schuchardt <xypron.glpk@gmx.de>
上级 70bad546
......@@ -646,7 +646,7 @@ static efi_status_t find_boot_device(void)
ret = get_dp_device(boot_var16, &boot_dev);
if (ret == EFI_SUCCESS) {
if (device_is_present_and_system_part(boot_dev)) {
goto out;
goto found;
} else {
efi_free_pool(boot_dev);
boot_dev = NULL;
......@@ -689,6 +689,7 @@ skip:
efi_free_pool(boot_dev);
boot_dev = NULL;
}
found:
if (boot_dev) {
u16 *path_str;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册