From nobody Tue Jan 24 22:13:43 2023 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 4P1h7r2318z3bgPB; Tue, 24 Jan 2023 22:13:44 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4P1h7r1RXlz3J4G; Tue, 24 Jan 2023 22:13:44 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1674598424; 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=TSeSpUnNsX/BK5cRMCMSt9+jLlZmqhNYnoV03hkDh90=; b=U+OBX89EOilxwh8ZihD1y7yvUhGJyjrrrUANzjxyf32WVwKgL6q4lqYZFDbB9mlpzzMQhX 9tXhRgVOMjh4ljvjiuwyA+WBzPVeGaBZNDyEoEm7lF/ALedAak7gYPq5W+fVpLvgCtGiA8 QLrLM5/vPhlKwuuDKe/VaRetrfK3tkTQqw9MHvfPN4bUIrfhtDh2hhOCmh2PnB+wUlpkXR uhRt8FcLqio8/gp61rkKPRUCZjdOB19WhOD3fx7O2MLC6T+FYBlSfoJqd3Aju2qNtvLNJ8 5basJKWFaf9VJERASD8Bdmpf3jKB4wWUshlYYScFtziTDUmbYKksKFedjDmTRA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1674598424; 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=TSeSpUnNsX/BK5cRMCMSt9+jLlZmqhNYnoV03hkDh90=; b=hHuPjogiz0y24MGxqNZTXJHLCsC9tyO4XqlAi4J7vfek+o6wdtJCkDoTCxB3V46kB8rKXd 9/LNVAbS/PXpoOV/UXcXFg1RGaeMaBOjVoUlOvPWQNPOxqwr+RhCG7cCcNRVKUWmKJBG92 Qh6/OYQDhDGuq7dXEzH4a7goMMOUkpT6itRW53P41xu1JaaNfLY+v+eTlxXFXaD0Dgw2gH yqebbkTE69y9dboprs0+LNwVBrR/QLgNRlQdV3MDAmTP0ctkJ9mBFwuko8Rz22R3+unO1R hAyCxf9QWbO+g2/U32SrDjX14vpvL18EhgKUNIukhufFlLYYYAlR9NlEx3B+8w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1674598424; a=rsa-sha256; cv=none; b=RiXejOuPXYFKscxMkftQFytaav9lv3CvRbr5sjRS6K/hJIW+cLu6cI4qK+kJcvM47BbXio wLvwqwvF4Z2kPragHsmrQipx+2chYyqpmbCbrm6zdxDnC766QFl12Qp1vgM/atscWSlySG izV0xe+j9lHZhI6Rt/5+cJbMXJU4ujd29/9lgXOprHmYeX5QHKTg/LaVNoVfFO6bItIqW8 Z8Io/TRxP0vBpXkymsL3/52v0ZXQNSshFjXsTphrfYhzqHDBjHJFKmNPoyqW9rIr2d1HJW Wv1Rf76T0xmES8h6eQ227iNIUZvh+2UfSbBe5AX/gi9hZ9k84eODZVJObk7FPg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (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 did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4P1h7r0WXVzQfV; Tue, 24 Jan 2023 22:13:44 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 30OMDhlf088829; Tue, 24 Jan 2023 22:13:43 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 30OMDhtI088828; Tue, 24 Jan 2023 22:13:43 GMT (envelope-from git) Date: Tue, 24 Jan 2023 22:13:43 GMT Message-Id: <202301242213.30OMDhtI088828@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 8bf162765f42 - stable/13 - stand/efi: Document the copy size trick 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: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 8bf162765f4268b31ac17e9fe398f69713752440 Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch stable/13 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=8bf162765f4268b31ac17e9fe398f69713752440 commit 8bf162765f4268b31ac17e9fe398f69713752440 Author: Warner Losh AuthorDate: 2022-12-04 00:23:16 +0000 Commit: Warner Losh CommitDate: 2023-01-24 21:49:41 +0000 stand/efi: Document the copy size trick We call bi_copymodules twice: once with 0 and once with the size of the arena. We do this to find the size, it turns out. Document this. Sponsored by: Netflix (cherry picked from commit 67e39a0d1bdb24967591721bf7c995d61e0e1c2d) --- stand/efi/loader/bootinfo.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stand/efi/loader/bootinfo.c b/stand/efi/loader/bootinfo.c index c5f0291c9e6e..b93f91dfaf15 100644 --- a/stand/efi/loader/bootinfo.c +++ b/stand/efi/loader/bootinfo.c @@ -415,7 +415,7 @@ bi_load(char *args, vm_offset_t *modulep, vm_offset_t *kernendp, bool exit_bs) #endif bi_load_efi_data(kfp, exit_bs); - size = md_copymodules(0, is64); + size = md_copymodules(0, is64); /* Find the size of the modules */ kernend = roundup(addr + size, PAGE_SIZE); *kernendp = kernend;