From nobody Fri Mar 20 14:44:51 2026 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4fclhg37jDz6W4yk for ; Fri, 20 Mar 2026 14:44:51 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R12" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4fclhg2Ndsz44yD for ; Fri, 20 Mar 2026 14:44:51 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1774017891; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=qvV7cRrXm+Y08LswHtEileelHemBEZv17R/pJPLCDlw=; b=QE7dmRPBsI8upMvvDXLiC7WrPFvDK4rBqRSMqad5bLgs8M/1euYWwOxiu3ZQZcRLTtb1Ks v8Mti8P7Si9al9OE8sXa1vVLxC4L42vLtq/lz3GDj6Ro6OfxwL+LGS2SIV45aKBGFlqoh4 fHrO0kXEhH54xf/54p0+VB3XO+Ayy6gU7bc1nCJIUY+puGRbSH4C1gZojqPYTUqq8m9FoG udo2BHLGD2oLyGJGljH4PXDywxdl1k/akEzY4BSTwOFkhVkvGLhaKkKiZa56k4DAg0IVpq sR7DfvkipslEZM9Lsxnf93xY7sNRa9MLbG0FVzA5+5HslNMWv7lHoVSleKG1Ww== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1774017891; a=rsa-sha256; cv=none; b=rhq3KjVwe0bC/ubBEKcLC7NFK/MNfQ2NpZYitGElNl+NeXdhBip7abbmScnC956uBe0bPa 1elg7vhTqkCe0gS9gtExXctXdeIshYF+6lqBKXSnU/CvMIdYOOzV0zAn3O0nEOW/oHiuJ6 BK+Pe/6ScsCN/ln+zQWLYYZdSmPKEd6lILxAPbyCk+ieNMPkbkiqLhyvX7dN+th/+ILUs4 j6eGesiCz+ske2/9kY+0bzvdLsMsVWGsrnQaQPFMNpv/Anlp/ha7oUw3PMTXXSmx6jP0rf ROCD1AguWwfJ+Uod8vTL4kMT6eAvKbQJykxVPW2ZTADx8N97xbPzupnZYLp+SA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1774017891; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=qvV7cRrXm+Y08LswHtEileelHemBEZv17R/pJPLCDlw=; b=FIaDQrYG8+51F3oWSpqvgc2uW5FBaMc2/P7Sd+Os9ZP1hlcnIjdog0BgkiVWpBKfXNY4My +EMHLYA7iDHQZgsNj2EOMiM3QxzS1k8jC63Ai9dm7RZXnj1mtJ8DGGvBLoL3Vo4uG9al2e Kf4aJzKEH5aILfZM/rJouivXX14MY7aEpXMsGUSze+FMDEAXKyZrwetOgxIHydmYept5Rp nx8WxL2DcZPkmYpiG0okpi6hRWCTBA9iCht6sJOIUKqwIWhXqkmB41q1BI9BpXOPbiGAas 3bvLzZiRW7OUM76Qf8UT+KyHM9SqU1dSQasFrJQdzOySQ67hSNv6jYQ2MNMIpw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4fclhg1zl5zVNH for ; Fri, 20 Mar 2026 14:44:51 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 1c826 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Fri, 20 Mar 2026 14:44:51 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Navdeep Parhar Subject: git: 0661997cea16 - main - loader(8): embedded MD should be the most preferred currdev List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 0661997cea165e951e4e215e6aed41596d8b1d52 Auto-Submitted: auto-generated Date: Fri, 20 Mar 2026 14:44:51 +0000 Message-Id: <69bd5d63.1c826.a325412@gitrepo.freebsd.org> The branch main has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=0661997cea165e951e4e215e6aed41596d8b1d52 commit 0661997cea165e951e4e215e6aed41596d8b1d52 Author: Navdeep Parhar AuthorDate: 2026-03-20 00:39:17 +0000 Commit: Navdeep Parhar CommitDate: 2026-03-20 14:40:41 +0000 loader(8): embedded MD should be the most preferred currdev A loader built with MD_IMAGE_SIZE is almost always meant for use with its embedded image and should try that as currdev before anything else. Recent changes (d69fc3a9dc71, 784150fd2535) seem to have relaxed the ZFS code's search for a rootfs and exposed this problem. Reviewed by: imp, tsoome MFC after: 1 week Sponsored by: Chelsio Communications Differential Revision: https://reviews.freebsd.org/D55979 --- stand/efi/loader/main.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/stand/efi/loader/main.c b/stand/efi/loader/main.c index f83db2e0668d..1fd6c8d74195 100644 --- a/stand/efi/loader/main.c +++ b/stand/efi/loader/main.c @@ -597,6 +597,15 @@ find_currdev(bool do_bootmgr, char *boot_info, size_t boot_info_sz) } /* Nothing specified, try normal match */ } +#ifdef MD_IMAGE_SIZE + /* + * If there is an embedded MD, try to use that. + */ + printf("Trying MD\n"); + if (probe_md_currdev()) + return (0); +#endif /* MD_IMAGE_SIZE */ + #ifdef EFI_ZFS_BOOT zfsinfo_list_t *zfsinfo = efizfs_get_zfsinfo_list(); zfsinfo_t *zi; @@ -616,15 +625,6 @@ find_currdev(bool do_bootmgr, char *boot_info, size_t boot_info_sz) } #endif /* EFI_ZFS_BOOT */ -#ifdef MD_IMAGE_SIZE - /* - * If there is an embedded MD, try to use that. - */ - printf("Trying MD\n"); - if (probe_md_currdev()) - return (0); -#endif /* MD_IMAGE_SIZE */ - /* * Try to find the block device by its handle based on the * image we're booting. If we can't find a sane partition,