Pull up following revision(s) (requested by riastradh in ticket #1828):

sys/stand/efiboot/efiboot.c: revision 1.23

efiboot: Duplicate efi_bootdp before we clobber it in efi_net_probe.

Patch from jakllsch@.  Makes Socionext Synquacer boot considerably
more reliably.

PR kern/58075
This commit is contained in:
martin 2024-04-18 15:33:44 +00:00
parent 39cc01ae79
commit aadaf7c76d
1 changed files with 3 additions and 1 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: efiboot.c,v 1.16.4.1 2019/09/26 19:15:18 martin Exp $ */ /* $NetBSD: efiboot.c,v 1.16.4.2 2024/04/18 15:33:44 martin Exp $ */
/*- /*-
* Copyright (c) 2018 Jared McNeill <jmcneill@invisible.ca> * Copyright (c) 2018 Jared McNeill <jmcneill@invisible.ca>
@ -84,6 +84,8 @@ efi_main(EFI_HANDLE imageHandle, EFI_SYSTEM_TABLE *systemTable)
status = uefi_call_wrapper(BS->HandleProtocol, 3, efi_li->DeviceHandle, &DevicePathProtocol, (void **)&efi_bootdp); status = uefi_call_wrapper(BS->HandleProtocol, 3, efi_li->DeviceHandle, &DevicePathProtocol, (void **)&efi_bootdp);
if (EFI_ERROR(status)) if (EFI_ERROR(status))
efi_bootdp = NULL; efi_bootdp = NULL;
else
efi_bootdp = DuplicateDevicePath(efi_bootdp);
#ifdef EFIBOOT_DEBUG #ifdef EFIBOOT_DEBUG
Print(L"Loaded image : 0x%" PRIxEFIPTR "\n", efi_li); Print(L"Loaded image : 0x%" PRIxEFIPTR "\n", efi_li);