From owner-svn-src-head@freebsd.org Thu Jul 26 05:08:59 2018 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 62B7C103DEB2; Thu, 26 Jul 2018 05:08:59 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 15C687DA64; Thu, 26 Jul 2018 05:08:59 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id EB32524781; Thu, 26 Jul 2018 05:08:58 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id w6Q58wAc064502; Thu, 26 Jul 2018 05:08:58 GMT (envelope-from imp@FreeBSD.org) Received: (from imp@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id w6Q58w8c064501; Thu, 26 Jul 2018 05:08:58 GMT (envelope-from imp@FreeBSD.org) Message-Id: <201807260508.w6Q58w8c064501@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: imp set sender to imp@FreeBSD.org using -f From: Warner Losh Date: Thu, 26 Jul 2018 05:08:58 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r336733 - head/stand/efi/loader X-SVN-Group: head X-SVN-Commit-Author: imp X-SVN-Commit-Paths: head/stand/efi/loader X-SVN-Commit-Revision: 336733 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.27 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 26 Jul 2018 05:08:59 -0000 Author: imp Date: Thu Jul 26 05:08:58 2018 New Revision: 336733 URL: https://svnweb.freebsd.org/changeset/base/336733 Log: Ignore Device Paths in the Boot Info that don't have Media path nodes. These show up in default entries on SuperMicro motherboards and elsewhere. Before, we couldn't find a block device associated with the device path and return BAD_CHOICE which was an instant failure. However, a VendHw node isn't specifc, so when we don't find a media path, return NOT_SPECIFIC so that the rest of the algorithms work. Sponsored by: Netflix. Modified: head/stand/efi/loader/main.c Modified: head/stand/efi/loader/main.c ============================================================================== --- head/stand/efi/loader/main.c Thu Jul 26 04:12:31 2018 (r336732) +++ head/stand/efi/loader/main.c Thu Jul 26 05:08:58 2018 (r336733) @@ -355,9 +355,14 @@ match_boot_info(EFI_LOADED_IMAGE *img __unused, char * /* * If there's only one item in the list, then nothing was - * specified. + * specified. Or if the last path doesn't have a media + * path in it. Those show up as various VenHw() nodes + * which are basically opaque to us. Don't count those + * as something specifc. */ if (last_dp == first_dp) + return NOT_SPECIFIC; + if (efi_devpath_to_media_path(last_dp) == NULL) return NOT_SPECIFIC; /*