diff options
author | 2015-11-26 20:26:20 +0000 | |
---|---|---|
committer | 2015-11-26 20:26:20 +0000 | |
commit | b26479004b6e195573271acef9e55d0f6ec81f08 (patch) | |
tree | 9d7e790487832a04f21995e0a0d7565764fbffb7 | |
parent | Fix "Bad value" error seen when building Mesa 11.0.6 which uses -Bsymbolic. (diff) | |
download | wireguard-openbsd-b26479004b6e195573271acef9e55d0f6ec81f08.tar.xz wireguard-openbsd-b26479004b6e195573271acef9e55d0f6ec81f08.zip |
Avoid setting mode to GOP if the mode is unchanged. Also don't panic
if the setting mode is failed.
reported and tested by Joe Gidi
-rw-r--r-- | sys/arch/amd64/stand/efiboot/efiboot.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/arch/amd64/stand/efiboot/efiboot.c b/sys/arch/amd64/stand/efiboot/efiboot.c index 6dad131f707..04d50719c5f 100644 --- a/sys/arch/amd64/stand/efiboot/efiboot.c +++ b/sys/arch/amd64/stand/efiboot/efiboot.c @@ -1,4 +1,4 @@ -/* $OpenBSD: efiboot.c,v 1.9 2015/11/08 00:17:29 yasuoka Exp $ */ +/* $OpenBSD: efiboot.c,v 1.10 2015/11/26 20:26:20 yasuoka Exp $ */ /* * Copyright (c) 2015 YASUOKA Masahiko <yasuoka@yasuoka.net> @@ -526,10 +526,10 @@ efi_makebootargs(void) bestsiz = gopsiz; } } - if (bestmode >= 0) { + if (bestmode >= 0 && conout->Mode->Mode != bestmode) { status = EFI_CALL(gop->SetMode, gop, bestmode); if (EFI_ERROR(status)) - panic("GOP setmode failed(%d)", status); + printf("GOP setmode failed(%d)\n", status); } gopi = gop->Mode->Info; |