From: "Mike Rapoport (Microsoft)" <rppt@kernel.org>
To: Jonathan Corbet <corbet@lwn.net>, Mike Rapoport <rppt@kernel.org>,
Pasha Tatashin <pasha.tatashin@soleen.com>,
Pratyush Yadav <pratyush@kernel.org>
Cc: Alexander Graf <graf@amazon.com>,
Andrew Morton <akpm@linux-foundation.org>,
Chen Pei <cp0613@linux.alibaba.com>,
George Guo <guodongtai@kylinos.cn>,
Kexin Liu <liukexin@kylinos.cn>,
Randy Dunlap <rdunlap@infradead.org>,
Shuah Khan <skhan@linuxfoundation.org>,
Sourabh Jain <sourabhjain@linux.ibm.com>,
kexec@lists.infradead.org, linux-doc@vger.kernel.org,
linux-kernel@vger.kernel.org, linux-mm@kvack.org
Subject: [PATCH v3 5/5] kho: docs: update description of bootmem regions
Date: Thu, 12 Nov 2026 12:38:57 +0200 [thread overview]
Message-ID: <20261112-kho-bootmem-sizing-v3-5-f0c8d00295d5@kernel.org> (raw)
In-Reply-To: <20261112-kho-bootmem-sizing-v3-0-f0c8d00295d5@kernel.org>
The description of the boot memory regions does not mention the low
memory region and claims there is always a region per node plus a global
region, while the low memory and the global regions are not allocated
when they would be empty.
List all types of the boot memory regions and describe when they are not
allocated.
While on it, fix grammar and split the description of the regions size
and of the CMA usage into separate paragraphs.
Signed-off-by: Mike Rapoport (Microsoft) <rppt@kernel.org>
---
Documentation/core-api/kho/index.rst | 31 ++++++++++++++++++++-----------
1 file changed, 20 insertions(+), 11 deletions(-)
diff --git a/Documentation/core-api/kho/index.rst b/Documentation/core-api/kho/index.rst
index e78a2bbe2be1d..ce2bf9cf66514 100644
--- a/Documentation/core-api/kho/index.rst
+++ b/Documentation/core-api/kho/index.rst
@@ -52,17 +52,26 @@ allocations before during boot up to the initialization of the page allocator.
We guarantee that we always have such regions through the boot memory regions:
On first boot KHO allocates several physically contiguous memory regions. Since
-after kexec these regions will be used by early memory allocations, there is a
-boot memory region per NUMA node plus a boot memory region to satisfy
-allocations requests that do not require particular NUMA node assignment. By
-default, size of the boot memory region is calculated based on amount of memory
-allocated during boot. The ``kho_bootmem`` kernel command line option may be
-used to explicitly define size of the boot memory regions. The boot memory
-regions are declared as CMA when page allocator is initialized so that their
-memory can be used during system lifetime. CMA gives us the guarantee that no
-handover pages land in that region, because handover pages must be at a static
-physical memory location and CMA enforces that only movable pages can be located
-inside.
+after kexec these regions will be used by early memory allocations, there are
+several types of such regions to ensure that all boot-time allocations work:
+
+* a low memory region for allocations below ``ARCH_LOW_ADDRESS_LIMIT``
+* a region per NUMA node
+* a global region for allocations that do not require a particular NUMA node
+
+Regions that would be empty are not allocated. For example, there is no low
+memory region when ``ARCH_LOW_ADDRESS_LIMIT`` covers all memory, and there is
+no global region when ``CONFIG_NUMA`` is disabled.
+
+By default, the size of the boot memory regions is calculated based on the
+amount of memory allocated during boot. The ``kho_bootmem`` kernel command line
+option may be used to explicitly define the size of the boot memory regions.
+
+The boot memory regions are declared as CMA when the page allocator is
+initialized so that their memory can be used during system lifetime. CMA gives
+us the guarantee that no handover pages land in that region, because handover
+pages must be at a static physical memory location and CMA enforces that only
+movable pages can be located inside.
After KHO kexec, we ignore the ``kho_bootmem`` kernel command line option and
instead reuse the exact same region that was originally allocated. This allows
--
2.53.0
prev parent reply other threads:[~2026-11-12 10:39 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-12 10:38 [PATCH v3 0/5] kho: fix bootmem sizing Mike Rapoport (Microsoft)
2026-11-12 10:38 ` [PATCH v3 1/5] kho: reject zero bootmem scale Mike Rapoport (Microsoft)
2026-11-12 10:38 ` [PATCH v3 2/5] kho: walk bootmem areas in address order Mike Rapoport (Microsoft)
2026-11-12 10:38 ` [PATCH v3 3/5] kho: skip zero-sized lowmem and global bootmem areas Mike Rapoport (Microsoft)
2026-11-12 10:38 ` [PATCH v3 4/5] kho: fix bootmem sizing Mike Rapoport (Microsoft)
2026-11-12 10:38 ` Mike Rapoport (Microsoft) [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20261112-kho-bootmem-sizing-v3-5-f0c8d00295d5@kernel.org \
--to=rppt@kernel.org \
--cc=akpm@linux-foundation.org \
--cc=corbet@lwn.net \
--cc=cp0613@linux.alibaba.com \
--cc=graf@amazon.com \
--cc=guodongtai@kylinos.cn \
--cc=kexec@lists.infradead.org \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=liukexin@kylinos.cn \
--cc=pasha.tatashin@soleen.com \
--cc=pratyush@kernel.org \
--cc=rdunlap@infradead.org \
--cc=skhan@linuxfoundation.org \
--cc=sourabhjain@linux.ibm.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®