From nobody Mon Sep 28 16:01:19 2026 X-Original-To: dev-commits-src-branches@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 4htmJH5Fmxz6WrvL for ; Mon, 28 Sep 2026 16:01:19 +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 "YR2" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4htmJH4krPz4T1P for ; Mon, 28 Sep 2026 16:01:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1790611279; 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=s0sOHprK95ya25qJl1BcESkZcTmdNzew7JK6JTL7jtc=; b=F7NRTcsaXWa3Nnc8StvE8xaSS3IVB3JZAN5pL+KG1L4O2m369XOFNxYBJAVdQp32hL3x2D IrBIjjrqtYYoC2+JOiqOpGD0YVyZptEiFxBr4sPUcky11mopviprptDj1w75HgWez8YpZy 5Je520JYVgUlY/TkpH6Y0e0Y4qxHh8eU4oftSCC/5D4SFGpBjDgPAU8SBRQLRgvgYZOTUN P4HsWEl/+pczptBurRlnLIlH9qxZpW3ZQJ9EAD8M0H6qAJKZqFdKNg+JxM2FdiHleBH82c VUEFsVC0Rdf+1g3cRZD/+pDBwYb08Uo8aKGsLKu1s0mTxvvlvnEr6LnxEvbOWg== ARC-Seal: i=1; a=rsa-sha256; d=freebsd.org; s=dkim; cv=none; t=1790611279; b=XmqJHnAc0wmzkbi673vJ5wfd1/ka0XxnRduHygf2bq/Zh+JSdsB/QSbInMRgUyTkMgcy+D tPjnCoISi9vKk94WKrR1zoeKqAU+ksokfGKmp1Jmu6asW7jxGWKHvNfu2zPqMFclRfZ1RO EDeKTRfJeGhroFokodGXX4LOlopa0hBmCioE0VEpSw1E3+4SZJOLMO2KJtWPL2mLTib7jn oi2Si7rY2AZ+tXc2O4/xylzMZaALQxGwFp/1bNLJiW0GThTJTG3N1dPejeJHqQfVOhDD0W BPbcMUWXaMYVCxaPkXMNqMefwwJSJm1xUMINn26nKGVcaqTUE51+iGyWMHvHsw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1790611279; 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=s0sOHprK95ya25qJl1BcESkZcTmdNzew7JK6JTL7jtc=; b=OFDiEr2QCUKWAURVayCPM0wv18Vf6Rp5DMedZHdlq2XO6FcNkp34/BdFll33VmQa+ypzW/ 7w5XAJOvF4V87RWxB2TBcoJj2W0hAEjwaB32+BYy7QpLeSL9dDpWAWjzTe+vyicAvyMqfe nkdK+NxFGnhD1vhBD/x6ib4fmePfka4+vgKeco9/GVCfVkqT53GIzSOhu4iLvL1QUfaO6o xuOX9GXSnbifUbvLfkUFYvYiqHAms4MU7pxBR7JyJGQPsGJFijbuSbZVBF4L2kglO+9Af8 neTjLZnfaF8E8zlnhx6ZD002oYqC2rqLbDmzIqgz6jgWZzruoqh2B2oTECndNA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4htmJH3mt6zbYL for ; Mon, 28 Sep 2026 16:01:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 25ae5 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Mon, 28 Sep 2026 16:01:19 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Roman Bogorodskiy Subject: git: 1a6e0c38d023 - stable/15 - bhyve: fix boot device ordering List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: novel X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 1a6e0c38d023f975d6015570b9fc34f09175dc03 Auto-Submitted: auto-generated Date: Mon, 28 Sep 2026 16:01:19 +0000 Message-Id: <6aba8f4f.25ae5.566d07ed@gitrepo.freebsd.org> The branch stable/15 has been updated by novel: URL: https://cgit.FreeBSD.org/src/commit/?id=1a6e0c38d023f975d6015570b9fc34f09175dc03 commit 1a6e0c38d023f975d6015570b9fc34f09175dc03 Author: Roman Bogorodskiy AuthorDate: 2026-09-20 14:41:55 +0000 Commit: Roman Bogorodskiy CommitDate: 2026-09-28 15:59:17 +0000 bhyve: fix boot device ordering EDK2's QemuBootOrderLib inspects the bootorder file provided via fw_cfg and requires it to be NUL-terminated. Otherwise, it rejects the supplied bootorder and falls back to its default boot order. Currently, bhyve registers bootorder with qemu_fwcfg_add_file() using bootorder_len returned by open_memstream(), which excludes the trailing NUL byte. Fix that by passing bootorder_len + 1 to qemu_fwcfg_add_file() so the fw_cfg payload is properly NUL-terminated. PR: 279720 Reviewed by: markj Found with: codex (gpt-5.6-sol) MFC after: 1 week Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D59859 (cherry picked from commit b27a221ef79d6d77d6173897f12118e1126453d8) --- usr.sbin/bhyve/pci_emul.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/usr.sbin/bhyve/pci_emul.c b/usr.sbin/bhyve/pci_emul.c index 538e4f284bec..228f797f8a86 100644 --- a/usr.sbin/bhyve/pci_emul.c +++ b/usr.sbin/bhyve/pci_emul.c @@ -1512,7 +1512,7 @@ init_bootorder(void) } fclose(fp); - return (qemu_fwcfg_add_file("bootorder", bootorder_len, bootorder)); + return (qemu_fwcfg_add_file("bootorder", bootorder_len + 1, bootorder)); } #define BUSIO_ROUNDUP 32