From nobody Thu Feb 02 20:07:36 2023 X-Original-To: dev-commits-src-all@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 4P78w83Tqkz3kX9m; Thu, 2 Feb 2023 20:07:36 +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 4P78w82yrXz4H7H; Thu, 2 Feb 2023 20:07:36 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1675368456; 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=TeuOFbd6IgUwL3tmIKqsnxV9W1gpG4V5vAJj5RS0sJs=; b=uYvXX6tzju/opUZ6Zc/zWyXt99JGBaAY50Jue/74A+5qDeEFY15anzGuHZ42ZM0FKgUCdK hVV/aJ2U1+YdA+y/q1SSDRXxR5AdiQUDTOoNgNKWNXRzMpseWHqK/abQiQTEeRi1924D4C oFSj9c1i0mAw4s85pKULTrCHdboskuodKDdup53A9Ol9eixMXpZoeAWCZcefZrj7YWdKxc aHYjy5RleokPStdE93b/VMLvS+selAM28Qqp6SEm5q3ZNnP7ax3BB6ETNXmKKvplgeH/Dn BgsaSP03A54JYO7WkcdE8i9FQ/FXd9Lo/0j+6MS8wjOCsxQEukY5Ho6dfTcjsQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1675368456; 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=TeuOFbd6IgUwL3tmIKqsnxV9W1gpG4V5vAJj5RS0sJs=; b=G68I2mVDQUAvsGZDZ4qMsCdvi0CQzVPOeB3fE4CG1vWWQoezO87TsE9ZJiASo794WEmUv0 GiYlUVTJmSAHzTzGzcg2AQjNYv/W5J9vOt+pTVt9qirqp57d5yD8Ailf1x2qNzHhhIQk6L jVuLF0ITfW7x6SnYNMFnywWWYIcmdrEaU6LZ1jZ0fRwWEX2Zl30dhc9FnKw1rbhMNaJO8c Af2x5tQnFC5fCtdzhhroVTe7jlktn8nZWXG0NeP/ORtt4n4nF9CsHRKmErQ+jSM35uZwDB D13AiGh528aPwqoh4yZLomnpsjl8BoBVmE1VfibRd9E066G3GnRsWaMZTVhnyA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1675368456; a=rsa-sha256; cv=none; b=rFSvLI8oZTUap9Z2LhrVDBYmyVD6hmOcu77H4I/LFxFgOHlkeRJUwGVsjsjH0C7sqGKuCC v/JIJ59fLjAbVGlbdT0U9zbbSDhOZ/z5rXIdwNPC5gXUOuAM0ABaO8mlCqF+1bgZowwI2/ nwohqUIKxNsF+XJPDJ4JVa7LFqtq7Dex2dr77PAvzXsCh6n6AWgeKJ372xxs0Nzej36F4K M1FbJoiVIZ7JjXMLgUWvbvKkB1FcBwl3oMIhzbKSIDzjGHUvh7q2wYUzMjErwqAI5RwJ5D UpRtX3S/LIXt98qac1f1loqDwjXK508nozd3Z0/PiFheV7EMbyCgtQ1R837b3Q== 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 4P78w81tLpz171R; Thu, 2 Feb 2023 20:07:36 +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 312K7amj036071; Thu, 2 Feb 2023 20:07:36 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 312K7akx036070; Thu, 2 Feb 2023 20:07:36 GMT (envelope-from git) Date: Thu, 2 Feb 2023 20:07:36 GMT Message-Id: <202302022007.312K7akx036070@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: 9fb276ea8001 - main - kboot: Trim initial allocation to 64MB List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@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/main X-Git-Reftype: branch X-Git-Commit: 9fb276ea800171b2065994b532931eb684777120 Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=9fb276ea800171b2065994b532931eb684777120 commit 9fb276ea800171b2065994b532931eb684777120 Author: Warner Losh AuthorDate: 2023-02-02 20:03:28 +0000 Commit: Warner Losh CommitDate: 2023-02-02 20:04:05 +0000 kboot: Trim initial allocation to 64MB We only need 64MB to read off ZFS pools. Since Linux doesn't do ovecommit by default, the extra 64MB is 64MB less we can allocate for things like RAM disks. Sponsored by: Netflix Reviewed by: kevans, andrew Differential Revision: https://reviews.freebsd.org/D38268 --- stand/kboot/main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/stand/kboot/main.c b/stand/kboot/main.c index 52c135f78582..7144f081e4dd 100644 --- a/stand/kboot/main.c +++ b/stand/kboot/main.c @@ -151,7 +151,7 @@ int main(int argc, const char **argv) { void *heapbase; - const size_t heapsize = 128*1024*1024; + const size_t heapsize = 64*1024*1024; const char *bootdev; archsw.arch_getdev = kboot_getdev; @@ -167,7 +167,7 @@ main(int argc, const char **argv) do_init(); /* - * Setup the heap 15MB should be plenty + * Setup the heap, 64MB is minimum for ZFS booting */ heapbase = host_getmem(heapsize); setheap(heapbase, heapbase + heapsize);