From nobody Sat Mar 09 04:40:43 2024 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 4Ts9Mb4GY0z5CqC6; Sat, 9 Mar 2024 04:40:43 +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 4Ts9Mb3Ym8z4nFn; Sat, 9 Mar 2024 04:40:43 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1709959243; 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=+Ph4J5iSaGboONPGHZZ9Bw/auJO9qKpFRtlCi/LlCxQ=; b=leng4LGvZOt/i3xR3PlR1jPVKb4AMkq6qXPHBYzdAJE5uSHnNfRPsO38bbqsiGbbCQzR3b 2TDGODIyyB15FBQj22IIMvRlAssd7su9hmcsuhj5uT6S0byARobPy0HPp5QvZqPYqiV3Ns YJPou8jRaYb0bxvlce/2ap3LcPTxBp0pwYioNUblriZBYur2SpAfdTSqHzvSjm8Xh7IbxS EtrGCo/S7epLom3EX8l43ZCSgMcmY0nCSHcbOgsGDtHUwDz6Oe7vECJREIjBvHypRZQztH UAG2Li/45M3ci6EjouQH4vHJR6W5joB+kXsrPV2FPaT8/7Q/dbgWgqThubUCQA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1709959243; a=rsa-sha256; cv=none; b=A6L+V4NnJYOAtDD7bZOufLADF9OugFIMPPb/LM9v33N22VlyOad2ZLR3tSXACMCM0wgQ6L mFmALLjEiwCfrHh67WUc1TXJYiMhyQI20Ld78F1W8nF/w1W2bcA2Vvji9IT7F1g973GMrD EzfOCjxcM0NWQnzWT8NSL8UEFgFyvIP812OWDKXouua8SdmqVNuaHvwQBBveBge4CuZ6jA 4e7eCUOE+jaHWamrsynYKOsTUt6pQ2FYeRWks5yYnllN5VgVzCDgInjKLKSrIGqWyZ72s2 NjaPt2k1nkFPinAZrzEZ26VWJ8lOnouAhSl4vc2nMj3hLS+GWzGt6wI9BKAq4w== 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=1709959243; 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=+Ph4J5iSaGboONPGHZZ9Bw/auJO9qKpFRtlCi/LlCxQ=; b=lvcq+PI6JRPwGOBIOGWGZBzQXdz9+q684FLjnPrfiwBdicBIZc0NdVhc4KaPEUIUjzuY+2 ai4/FfGELioEPnZXhy9Umw0oXk4Mvpqq6TX1ACLF6Hv5wJbCkSnXSj7PVEKNpkFJm3cDu/ jHF1sVO47gY+N1QKGAMnSglFKLPXiBzb8/epSfA5yPZ6EH5LpCDP4FOHE/A3R6IfS0J7cN KUG55J7vf1MNVbFR5KJSxGnQMnobSDI0S/lMDg+k91ZlFSEDHBqtDtfgNRdfALyQCwd+3s DYpIozka+ajmncqLVcfEmxSpCRggGaA/3atls6pDkK3t+DaPDDeRAkKB9zh21g== 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 4Ts9Mb322zznqM; Sat, 9 Mar 2024 04:40:43 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 4294ehKa030755; Sat, 9 Mar 2024 04:40:43 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 4294ehRO030753; Sat, 9 Mar 2024 04:40:43 GMT (envelope-from git) Date: Sat, 9 Mar 2024 04:40:43 GMT Message-Id: <202403090440.4294ehRO030753@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: 69c4a0ef86a2 - stable/14 - arm64: Add a VM_FREELIST_DMA32 freelist 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: markj X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 69c4a0ef86a22b384d887d5dae76cc13af43b5eb Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=69c4a0ef86a22b384d887d5dae76cc13af43b5eb commit 69c4a0ef86a22b384d887d5dae76cc13af43b5eb Author: Mark Johnston AuthorDate: 2024-01-25 21:33:46 +0000 Commit: Mark Johnston CommitDate: 2024-03-09 04:26:57 +0000 arm64: Add a VM_FREELIST_DMA32 freelist When booting a KMSAN kernel on an Ampere Altra, I've seen some boot time hangs when the XHCI controller driver attempts to allocate memory for 32-bit DMA. The system boots fine with a GENERIC kernel; I believe that the additional memory requirements of KMSAN push it over the edge. The system has a bit less than 2GB of RAM below the 4GB boundary. Allocate a new freelist to segregate memory below 4GB, as we do on amd64, so that such memory allocation failures are less likely to occur. Reviewed by: alc MFC after: 1 month Sponsored by: Klara, Inc. Sponsored by: Juniper Networks, Inc. Differential Revision: https://reviews.freebsd.org/D43503 (cherry picked from commit 48d5dab7bace6bae938672784ca3aa8733d72eb9) --- sys/arm64/include/vmparam.h | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/sys/arm64/include/vmparam.h b/sys/arm64/include/vmparam.h index 29fbf6221980..0176045f0cae 100644 --- a/sys/arm64/include/vmparam.h +++ b/sys/arm64/include/vmparam.h @@ -85,11 +85,13 @@ #define VM_FREEPOOL_DIRECT 1 /* - * Create one free page lists: VM_FREELIST_DEFAULT is for all physical - * pages. + * Create two free page lists: VM_FREELIST_DMA32 is for physical pages that have + * physical addresses below 4G, and VM_FREELIST_DEFAULT is for all other + * physical pages. */ -#define VM_NFREELIST 1 +#define VM_NFREELIST 2 #define VM_FREELIST_DEFAULT 0 +#define VM_FREELIST_DMA32 1 /* * When PAGE_SIZE is 4KB, an allocation size of 16MB is supported in order