€•©oŒsphinx.addnodes”Œdocument”“”)”}”(Œ rawsource”Œ”Œchildren”]”(Œ translations”Œ LanguagesNode”“”)”}”(hhh]”(hŒ pending_xref”“”)”}”(hhh]”Œdocutils.nodes”ŒText”“”ŒChinese (Simplified)”…””}”Œparent”hsbaŒ attributes”}”(Œids”]”Œclasses”]”Œnames”]”Œdupnames”]”Œbackrefs”]”Œ refdomain”Œstd”Œreftype”Œdoc”Œ reftarget”Œ3/translations/zh_CN/driver-api/cxl/linux/early-boot”Œmodname”NŒ classname”NŒ refexplicit”ˆuŒtagname”hhh ubh)”}”(hhh]”hŒChinese (Traditional)”…””}”hh2sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ3/translations/zh_TW/driver-api/cxl/linux/early-boot”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒItalian”…””}”hhFsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ3/translations/it_IT/driver-api/cxl/linux/early-boot”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒJapanese”…””}”hhZsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ3/translations/ja_JP/driver-api/cxl/linux/early-boot”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒKorean”…””}”hhnsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ3/translations/ko_KR/driver-api/cxl/linux/early-boot”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒPortuguese (Brazilian)”…””}”hh‚sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ3/translations/pt_BR/driver-api/cxl/linux/early-boot”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒSpanish”…””}”hh–sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ3/translations/sp_SP/driver-api/cxl/linux/early-boot”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubeh}”(h]”h ]”h"]”h$]”h&]”Œcurrent_language”ŒEnglish”uh1h hhŒ _document”hŒsource”NŒline”NubhŒcomment”“”)”}”(hŒ SPDX-License-Identifier: GPL-2.0”h]”hŒ SPDX-License-Identifier: GPL-2.0”…””}”hh·sbah}”(h]”h ]”h"]”h$]”h&]”Œ xml:space”Œpreserve”uh1hµhhh²hh³ŒM/var/lib/git/docbuild/linux/Documentation/driver-api/cxl/linux/early-boot.rst”h´KubhŒsection”“”)”}”(hhh]”(hŒtitle”“”)”}”(hŒLinux Init (Early Boot)”h]”hŒLinux Init (Early Boot)”…””}”(hhÏh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhhÊh²hh³hÇh´KubhŒ paragraph”“”)”}”(hŒRLinux configuration is split into two major steps: Early-Boot and everything else.”h]”hŒRLinux configuration is split into two major steps: Early-Boot and everything else.”…””}”(hhßh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´KhhÊh²hubhÞ)”}”(hX During early boot, Linux sets up immutable resources (such as numa nodes), while later operations include things like driver probe and memory hotplug. Linux may read EFI and ACPI information throughout this process to configure logical representations of the devices.”h]”hX During early boot, Linux sets up immutable resources (such as numa nodes), while later operations include things like driver probe and memory hotplug. Linux may read EFI and ACPI information throughout this process to configure logical representations of the devices.”…””}”(hhíh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K hhÊh²hubhÞ)”}”(hŒíDuring Linux Early Boot stage (functions in the kernel that have the __init decorator), the system takes the resources created by EFI/BIOS (:doc:`ACPI tables <../platform/acpi>`) and turns them into resources that the kernel can consume.”h]”(hŒŒDuring Linux Early Boot stage (functions in the kernel that have the __init decorator), the system takes the resources created by EFI/BIOS (”…””}”(hhûh²hh³Nh´Nubh)”}”(hŒ%:doc:`ACPI tables <../platform/acpi>`”h]”hŒinline”“”)”}”(hjh]”hŒ ACPI tables”…””}”(hj h²hh³Nh´Nubah}”(h]”h ]”(Œxref”Œstd”Œstd-doc”eh"]”h$]”h&]”uh1jhjubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”Œdriver-api/cxl/linux/early-boot”Œ refdomain”jŒreftype”Œdoc”Œ refexplicit”ˆŒrefwarn”ˆŒ reftarget”Œ../platform/acpi”uh1hh³hÇh´KhhûubhŒ<) and turns them into resources that the kernel can consume.”…””}”(hhûh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´KhhÊh²hubhÉ)”}”(hhh]”(hÎ)”}”(hŒBIOS, Build and Boot Options”h]”hŒBIOS, Build and Boot Options”…””}”(hj5h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhj2h²hh³hÇh´KubhÞ)”}”(hŒThere are 4 pre-boot options that need to be considered during kernel build which dictate how memory will be managed by Linux during early boot.”h]”hŒThere are 4 pre-boot options that need to be considered during kernel build which dictate how memory will be managed by Linux during early boot.”…””}”(hjCh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´Khj2h²hubhŒ bullet_list”“”)”}”(hhh]”(hŒ list_item”“”)”}”(hŒÐEFI_MEMORY_SP * BIOS/EFI Option that dictates whether memory is SystemRAM or Specific Purpose. Specific Purpose memory will be deferred to drivers to manage - and not immediately exposed as system RAM. ”h]”(hÞ)”}”(hŒ EFI_MEMORY_SP”h]”hŒ EFI_MEMORY_SP”…””}”(hj\h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´KhjXubjR)”}”(hhh]”jW)”}”(hŒ»BIOS/EFI Option that dictates whether memory is SystemRAM or Specific Purpose. Specific Purpose memory will be deferred to drivers to manage - and not immediately exposed as system RAM. ”h]”hÞ)”}”(hŒºBIOS/EFI Option that dictates whether memory is SystemRAM or Specific Purpose. Specific Purpose memory will be deferred to drivers to manage - and not immediately exposed as system RAM.”h]”hŒºBIOS/EFI Option that dictates whether memory is SystemRAM or Specific Purpose. Specific Purpose memory will be deferred to drivers to manage - and not immediately exposed as system RAM.”…””}”(hjqh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´Khjmubah}”(h]”h ]”h"]”h$]”h&]”uh1jVhjjubah}”(h]”h ]”h"]”h$]”h&]”Œbullet”Œ*”uh1jQh³hÇh´KhjXubeh}”(h]”h ]”h"]”h$]”h&]”uh1jVhjSh²hh³Nh´NubjW)”}”(hŒzCONFIG_EFI_SOFT_RESERVE * Linux Build config option that dictates whether the kernel supports Specific Purpose memory. ”h]”(hÞ)”}”(hŒCONFIG_EFI_SOFT_RESERVE”h]”hŒCONFIG_EFI_SOFT_RESERVE”…””}”(hj—h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K hj“ubjR)”}”(hhh]”jW)”}”(hŒ]Linux Build config option that dictates whether the kernel supports Specific Purpose memory. ”h]”hÞ)”}”(hŒ\Linux Build config option that dictates whether the kernel supports Specific Purpose memory.”h]”hŒ\Linux Build config option that dictates whether the kernel supports Specific Purpose memory.”…””}”(hj¬h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K"hj¨ubah}”(h]”h ]”h"]”h$]”h&]”uh1jVhj¥ubah}”(h]”h ]”h"]”h$]”h&]”j‹jŒuh1jQh³hÇh´K"hj“ubeh}”(h]”h ]”h"]”h$]”h&]”uh1jVhjSh²hh³Nh´NubjW)”}”(hŒáCONFIG_MHP_DEFAULT_ONLINE_TYPE * Linux Build config that dictates whether and how Specific Purpose memory converted to a dax device should be managed (left as DAX or onlined as SystemRAM in ZONE_NORMAL or ZONE_MOVABLE). ”h]”(hÞ)”}”(hŒCONFIG_MHP_DEFAULT_ONLINE_TYPE”h]”hŒCONFIG_MHP_DEFAULT_ONLINE_TYPE”…””}”(hjÐh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K%hjÌubjR)”}”(hhh]”jW)”}”(hŒ»Linux Build config that dictates whether and how Specific Purpose memory converted to a dax device should be managed (left as DAX or onlined as SystemRAM in ZONE_NORMAL or ZONE_MOVABLE). ”h]”hÞ)”}”(hŒºLinux Build config that dictates whether and how Specific Purpose memory converted to a dax device should be managed (left as DAX or onlined as SystemRAM in ZONE_NORMAL or ZONE_MOVABLE).”h]”hŒºLinux Build config that dictates whether and how Specific Purpose memory converted to a dax device should be managed (left as DAX or onlined as SystemRAM in ZONE_NORMAL or ZONE_MOVABLE).”…””}”(hjåh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K'hjáubah}”(h]”h ]”h"]”h$]”h&]”uh1jVhjÞubah}”(h]”h ]”h"]”h$]”h&]”j‹jŒuh1jQh³hÇh´K'hjÌubeh}”(h]”h ]”h"]”h$]”h&]”uh1jVhjSh²hh³Nh´NubjW)”}”(hŒ‰nosoftreserve * Linux kernel boot option that dictates whether Soft Reserve should be supported. Similar to CONFIG_EFI_SOFT_RESERVE. ”h]”(hÞ)”}”(hŒ nosoftreserve”h]”hŒ nosoftreserve”…””}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K+hjubjR)”}”(hhh]”jW)”}”(hŒvLinux kernel boot option that dictates whether Soft Reserve should be supported. Similar to CONFIG_EFI_SOFT_RESERVE. ”h]”hÞ)”}”(hŒuLinux kernel boot option that dictates whether Soft Reserve should be supported. Similar to CONFIG_EFI_SOFT_RESERVE.”h]”hŒuLinux kernel boot option that dictates whether Soft Reserve should be supported. Similar to CONFIG_EFI_SOFT_RESERVE.”…””}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K-hjubah}”(h]”h ]”h"]”h$]”h&]”uh1jVhjubah}”(h]”h ]”h"]”h$]”h&]”j‹jŒuh1jQh³hÇh´K-hjubeh}”(h]”h ]”h"]”h$]”h&]”uh1jVhjSh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”j‹jŒuh1jQh³hÇh´Khj2h²hubeh}”(h]”Œbios-build-and-boot-options”ah ]”h"]”Œbios, build and boot options”ah$]”h&]”uh1hÈhhÊh²hh³hÇh´KubhÉ)”}”(hhh]”(hÎ)”}”(hŒMemory Map Creation”h]”hŒMemory Map Creation”…””}”(hjOh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhjLh²hh³hÇh´K1ubhÞ)”}”(hŒ¡While the kernel parses the EFI memory map, if :code:`Specific Purpose` memory is supported and detected, it will set this region aside as :code:`SOFT_RESERVED`.”h]”(hŒ/While the kernel parses the EFI memory map, if ”…””}”(hj]h²hh³Nh´NubhŒliteral”“”)”}”(hŒ:code:`Specific Purpose`”h]”hŒSpecific Purpose”…””}”(hjgh²hh³Nh´Nubah}”(h]”h ]”Œcode”ah"]”h$]”h&]”Œlanguage”huh1jehj]ubhŒD memory is supported and detected, it will set this region aside as ”…””}”(hj]h²hh³Nh´Nubjf)”}”(hŒ:code:`SOFT_RESERVED`”h]”hŒ SOFT_RESERVED”…””}”(hj{h²hh³Nh´Nubah}”(h]”h ]”jrah"]”h$]”h&]”Œlanguage”huh1jehj]ubhŒ.”…””}”(hj]h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K3hjLh²hubhÞ)”}”(hXKIf :code:`EFI_MEMORY_SP=0`, :code:`CONFIG_EFI_SOFT_RESERVE=n`, or :code:`nosoftreserve=y` - Linux will default a CXL device memory region to SystemRAM. This will expose the memory to the kernel page allocator in :code:`ZONE_NORMAL`, making it available for use for most allocations (including :code:`struct page` and page tables).”h]”(hŒIf ”…””}”(hj”h²hh³Nh´Nubjf)”}”(hŒ:code:`EFI_MEMORY_SP=0`”h]”hŒEFI_MEMORY_SP=0”…””}”(hjœh²hh³Nh´Nubah}”(h]”h ]”jrah"]”h$]”h&]”Œlanguage”huh1jehj”ubhŒ, ”…””}”(hj”h²hh³Nh´Nubjf)”}”(hŒ!:code:`CONFIG_EFI_SOFT_RESERVE=n`”h]”hŒCONFIG_EFI_SOFT_RESERVE=n”…””}”(hj¯h²hh³Nh´Nubah}”(h]”h ]”jrah"]”h$]”h&]”Œlanguage”huh1jehj”ubhŒ, or ”…””}”(hj”h²hh³Nh´Nubjf)”}”(hŒ:code:`nosoftreserve=y`”h]”hŒnosoftreserve=y”…””}”(hjÂh²hh³Nh´Nubah}”(h]”h ]”jrah"]”h$]”h&]”Œlanguage”huh1jehj”ubhŒ| - Linux will default a CXL device memory region to SystemRAM. This will expose the memory to the kernel page allocator in ”…””}”(hj”h²hh³Nh´Nubjf)”}”(hŒ:code:`ZONE_NORMAL`”h]”hŒ ZONE_NORMAL”…””}”(hjÕh²hh³Nh´Nubah}”(h]”h ]”jrah"]”h$]”h&]”Œlanguage”huh1jehj”ubhŒ>, making it available for use for most allocations (including ”…””}”(hj”h²hh³Nh´Nubjf)”}”(hŒ:code:`struct page`”h]”hŒ struct page”…””}”(hjèh²hh³Nh´Nubah}”(h]”h ]”jrah"]”h$]”h&]”Œlanguage”huh1jehj”ubhŒ and page tables).”…””}”(hj”h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K7hjLh²hubhÞ)”}”(hXIf `Specific Purpose` is set and supported, :code:`CONFIG_MHP_DEFAULT_ONLINE_TYPE_*` dictates whether the memory is onlined by default (:code:`_OFFLINE` or :code:`_ONLINE_*`), and if online which zone to online this memory to by default (:code:`_NORMAL` or :code:`_MOVABLE`).”h]”(hŒIf ”…””}”(hjh²hh³Nh´NubhŒtitle_reference”“”)”}”(hŒ`Specific Purpose`”h]”hŒSpecific Purpose”…””}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1j hjubhŒ is set and supported, ”…””}”(hjh²hh³Nh´Nubjf)”}”(hŒ(:code:`CONFIG_MHP_DEFAULT_ONLINE_TYPE_*`”h]”hŒ CONFIG_MHP_DEFAULT_ONLINE_TYPE_*”…””}”(hjh²hh³Nh´Nubah}”(h]”h ]”jrah"]”h$]”h&]”Œlanguage”huh1jehjubhŒ4 dictates whether the memory is onlined by default (”…””}”(hjh²hh³Nh´Nubjf)”}”(hŒ:code:`_OFFLINE`”h]”hŒ_OFFLINE”…””}”(hj0h²hh³Nh´Nubah}”(h]”h ]”jrah"]”h$]”h&]”Œlanguage”huh1jehjubhŒ or ”…””}”(hjh²hh³Nh´Nubjf)”}”(hŒ:code:`_ONLINE_*`”h]”hŒ _ONLINE_*”…””}”(hjCh²hh³Nh´Nubah}”(h]”h ]”jrah"]”h$]”h&]”Œlanguage”huh1jehjubhŒA), and if online which zone to online this memory to by default (”…””}”(hjh²hh³Nh´Nubjf)”}”(hŒ:code:`_NORMAL`”h]”hŒ_NORMAL”…””}”(hjVh²hh³Nh´Nubah}”(h]”h ]”jrah"]”h$]”h&]”Œlanguage”huh1jehjubhŒ or ”…””}”(hjh²hh³Nh´Nubjf)”}”(hŒ:code:`_MOVABLE`”h]”hŒ_MOVABLE”…””}”(hjih²hh³Nh´Nubah}”(h]”h ]”jrah"]”h$]”h&]”Œlanguage”huh1jehjubhŒ).”…””}”(hjh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K=hjLh²hubhÞ)”}”(hŒæIf placed in :code:`ZONE_MOVABLE`, the memory will not be available for most kernel allocations (such as :code:`struct page` or page tables). This may significant impact performance depending on the memory capacity of the system.”h]”(hŒ If placed in ”…””}”(hj‚h²hh³Nh´Nubjf)”}”(hŒ:code:`ZONE_MOVABLE`”h]”hŒ ZONE_MOVABLE”…””}”(hjŠh²hh³Nh´Nubah}”(h]”h ]”jrah"]”h$]”h&]”Œlanguage”huh1jehj‚ubhŒH, the memory will not be available for most kernel allocations (such as ”…””}”(hj‚h²hh³Nh´Nubjf)”}”(hŒ:code:`struct page`”h]”hŒ struct page”…””}”(hjh²hh³Nh´Nubah}”(h]”h ]”jrah"]”h$]”h&]”Œlanguage”huh1jehj‚ubhŒj or page tables). This may significant impact performance depending on the memory capacity of the system.”…””}”(hj‚h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´KBhjLh²hubeh}”(h]”Œmemory-map-creation”ah ]”h"]”Œmemory map creation”ah$]”h&]”uh1hÈhhÊh²hh³hÇh´K1ubhÉ)”}”(hhh]”(hÎ)”}”(hŒNUMA Node Reservation”h]”hŒNUMA Node Reservation”…””}”(hjÁh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhj¾h²hh³hÇh´KHubhÞ)”}”(hŒàLinux refers to the proximity domains (:code:`PXM`) defined in the :doc:`SRAT <../platform/acpi/srat>` to create NUMA nodes in :code:`acpi_numa_init`. Typically, there is a 1:1 relation between :code:`PXM` and NUMA node IDs.”h]”(hŒ'Linux refers to the proximity domains (”…””}”(hjÏh²hh³Nh´Nubjf)”}”(hŒ :code:`PXM`”h]”hŒPXM”…””}”(hj×h²hh³Nh´Nubah}”(h]”h ]”jrah"]”h$]”h&]”Œlanguage”huh1jehjÏubhŒ) defined in the ”…””}”(hjÏh²hh³Nh´Nubh)”}”(hŒ#:doc:`SRAT <../platform/acpi/srat>`”h]”j)”}”(hjìh]”hŒSRAT”…””}”(hjîh²hh³Nh´Nubah}”(h]”h ]”(jŒstd”Œstd-doc”eh"]”h$]”h&]”uh1jhjêubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j Œ refdomain”jøŒreftype”Œdoc”Œ refexplicit”ˆŒrefwarn”ˆj&Œ../platform/acpi/srat”uh1hh³hÇh´KJhjÏubhŒ to create NUMA nodes in ”…””}”(hjÏh²hh³Nh´Nubjf)”}”(hŒ:code:`acpi_numa_init`”h]”hŒacpi_numa_init”…””}”(hjh²hh³Nh´Nubah}”(h]”h ]”jrah"]”h$]”h&]”Œlanguage”huh1jehjÏubhŒ-. Typically, there is a 1:1 relation between ”…””}”(hjÏh²hh³Nh´Nubjf)”}”(hŒ :code:`PXM`”h]”hŒPXM”…””}”(hj!h²hh³Nh´Nubah}”(h]”h ]”jrah"]”h$]”h&]”Œlanguage”huh1jehjÏubhŒ and NUMA node IDs.”…””}”(hjÏh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´KJhj¾h²hubhÞ)”}”(hŒòThe SRAT is the only ACPI defined way of defining Proximity Domains. Linux chooses to, at most, map those 1:1 with NUMA nodes. :doc:`CEDT <../platform/acpi/cedt>` adds a description of SPA ranges which Linux may map to one or more NUMA nodes.”h]”(hŒThe SRAT is the only ACPI defined way of defining Proximity Domains. Linux chooses to, at most, map those 1:1 with NUMA nodes. ”…””}”(hj:h²hh³Nh´Nubh)”}”(hŒ#:doc:`CEDT <../platform/acpi/cedt>`”h]”j)”}”(hjDh]”hŒCEDT”…””}”(hjFh²hh³Nh´Nubah}”(h]”h ]”(jŒstd”Œstd-doc”eh"]”h$]”h&]”uh1jhjBubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j Œ refdomain”jPŒreftype”Œdoc”Œ refexplicit”ˆŒrefwarn”ˆj&Œ../platform/acpi/cedt”uh1hh³hÇh´KNhj:ubhŒP adds a description of SPA ranges which Linux may map to one or more NUMA nodes.”…””}”(hj:h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´KNhj¾h²hubhÞ)”}”(hŒÙIf there are CXL ranges in the CFMWS but not in SRAT, then a fake :code:`PXM` is created (as of v6.15). In the future, Linux may reject CFMWS not described by SRAT due to the ambiguity of proximity domain association.”h]”(hŒBIf there are CXL ranges in the CFMWS but not in SRAT, then a fake ”…””}”(hjlh²hh³Nh´Nubjf)”}”(hŒ :code:`PXM`”h]”hŒPXM”…””}”(hjth²hh³Nh´Nubah}”(h]”h ]”jrah"]”h$]”h&]”Œlanguage”huh1jehjlubhŒŒ is created (as of v6.15). In the future, Linux may reject CFMWS not described by SRAT due to the ambiguity of proximity domain association.”…””}”(hjlh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´KShj¾h²hubhÞ)”}”(hX0It is important to note that NUMA node creation cannot be done at runtime. All possible NUMA nodes are identified at :code:`__init` time, more specifically during :code:`mm_init`. The CEDT and SRAT must contain sufficient :code:`PXM` data for Linux to identify NUMA nodes their associated memory regions.”h]”(hŒuIt is important to note that NUMA node creation cannot be done at runtime. All possible NUMA nodes are identified at ”…””}”(hjh²hh³Nh´Nubjf)”}”(hŒ:code:`__init`”h]”hŒ__init”…””}”(hj•h²hh³Nh´Nubah}”(h]”h ]”jrah"]”h$]”h&]”Œlanguage”huh1jehjubhŒ time, more specifically during ”…””}”(hjh²hh³Nh´Nubjf)”}”(hŒ:code:`mm_init`”h]”hŒmm_init”…””}”(hj¨h²hh³Nh´Nubah}”(h]”h ]”jrah"]”h$]”h&]”Œlanguage”huh1jehjubhŒ,. The CEDT and SRAT must contain sufficient ”…””}”(hjh²hh³Nh´Nubjf)”}”(hŒ :code:`PXM`”h]”hŒPXM”…””}”(hj»h²hh³Nh´Nubah}”(h]”h ]”jrah"]”h$]”h&]”Œlanguage”huh1jehjubhŒG data for Linux to identify NUMA nodes their associated memory regions.”…””}”(hjh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´KWhj¾h²hubhÞ)”}”(hŒDThe relevant code exists in: :code:`linux/drivers/acpi/numa/srat.c`.”h]”(hŒThe relevant code exists in: ”…””}”(hjÔh²hh³Nh´Nubjf)”}”(hŒ&:code:`linux/drivers/acpi/numa/srat.c`”h]”hŒlinux/drivers/acpi/numa/srat.c”…””}”(hjÜh²hh³Nh´Nubah}”(h]”h ]”jrah"]”h$]”h&]”Œlanguage”huh1jehjÔubhŒ.”…””}”(hjÔh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K\hj¾h²hubhÞ)”}”(hŒWSee :doc:`Example Platform Configurations <../platform/example-configs>` for more info.”h]”(hŒSee ”…””}”(hjõh²hh³Nh´Nubh)”}”(hŒD:doc:`Example Platform Configurations <../platform/example-configs>`”h]”j)”}”(hjÿh]”hŒExample Platform Configurations”…””}”(hjh²hh³Nh´Nubah}”(h]”h ]”(jŒstd”Œstd-doc”eh"]”h$]”h&]”uh1jhjýubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j Œ refdomain”j Œreftype”Œdoc”Œ refexplicit”ˆŒrefwarn”ˆj&Œ../platform/example-configs”uh1hh³hÇh´K^hjõubhŒ for more info.”…””}”(hjõh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K^hj¾h²hubeh}”(h]”Œnuma-node-reservation”ah ]”h"]”Œnuma node reservation”ah$]”h&]”uh1hÈhhÊh²hh³hÇh´KHubhÉ)”}”(hhh]”(hÎ)”}”(hŒMemory Tiers Creation”h]”hŒMemory Tiers Creation”…””}”(hj2h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhj/h²hh³hÇh´KbubhÞ)”}”(hŒÓMemory tiers are a collection of NUMA nodes grouped by performance characteristics. During :code:`__init`, Linux initializes the system with a default memory tier that contains all nodes marked :code:`N_MEMORY`.”h]”(hŒ[Memory tiers are a collection of NUMA nodes grouped by performance characteristics. During ”…””}”(hj@h²hh³Nh´Nubjf)”}”(hŒ:code:`__init`”h]”hŒ__init”…””}”(hjHh²hh³Nh´Nubah}”(h]”h ]”jrah"]”h$]”h&]”Œlanguage”huh1jehj@ubhŒY, Linux initializes the system with a default memory tier that contains all nodes marked ”…””}”(hj@h²hh³Nh´Nubjf)”}”(hŒ:code:`N_MEMORY`”h]”hŒN_MEMORY”…””}”(hj[h²hh³Nh´Nubah}”(h]”h ]”jrah"]”h$]”h&]”Œlanguage”huh1jehj@ubhŒ.”…””}”(hj@h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´Kchj/h²hubhÞ)”}”(hŒ½:code:`memory_tier_init` is called at boot for all nodes with memory online by default. :code:`memory_tier_late_init` is called during late-init for nodes setup during driver configuration.”h]”(jf)”}”(hŒ:code:`memory_tier_init`”h]”hŒmemory_tier_init”…””}”(hjxh²hh³Nh´Nubah}”(h]”h ]”jrah"]”h$]”h&]”Œlanguage”huh1jehjtubhŒ@ is called at boot for all nodes with memory online by default. ”…””}”(hjth²hh³Nh´Nubjf)”}”(hŒ:code:`memory_tier_late_init`”h]”hŒmemory_tier_late_init”…””}”(hj‹h²hh³Nh´Nubah}”(h]”h ]”jrah"]”h$]”h&]”Œlanguage”huh1jehjtubhŒH is called during late-init for nodes setup during driver configuration.”…””}”(hjth²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´Kghj/h²hubhÞ)”}”(hŒDNodes are only marked :code:`N_MEMORY` if they have *online* memory.”h]”(hŒNodes are only marked ”…””}”(hj¤h²hh³Nh´Nubjf)”}”(hŒ:code:`N_MEMORY`”h]”hŒN_MEMORY”…””}”(hj¬h²hh³Nh´Nubah}”(h]”h ]”jrah"]”h$]”h&]”Œlanguage”huh1jehj¤ubhŒ if they have ”…””}”(hj¤h²hh³Nh´NubhŒemphasis”“”)”}”(hŒ*online*”h]”hŒonline”…””}”(hjÁh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1j¿hj¤ubhŒ memory.”…””}”(hj¤h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´Kkhj/h²hubhÞ)”}”(hŒ&Tier membership can be inspected in ::”h]”hŒ#Tier membership can be inspected in”…””}”(hjÙh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´Kmhj/h²hubhŒ literal_block”“”)”}”(hŒ=/sys/devices/virtual/memory_tiering/memory_tierN/nodelist 0-1”h]”hŒ=/sys/devices/virtual/memory_tiering/memory_tierN/nodelist 0-1”…””}”hjésbah}”(h]”h ]”h"]”h$]”h&]”hÅhÆuh1jçh³hÇh´Kohj/h²hubhÞ)”}”(hXIf nodes are grouped which have clear difference in performance, check the :doc:`HMAT <../platform/acpi/hmat>` and CDAT information for the CXL nodes. All nodes default to the DRAM tier, unless HMAT/CDAT information is reported to the memory_tier component via `access_coordinates`.”h]”(hŒKIf nodes are grouped which have clear difference in performance, check the ”…””}”(hj÷h²hh³Nh´Nubh)”}”(hŒ#:doc:`HMAT <../platform/acpi/hmat>`”h]”j)”}”(hjh]”hŒHMAT”…””}”(hjh²hh³Nh´Nubah}”(h]”h ]”(jŒstd”Œstd-doc”eh"]”h$]”h&]”uh1jhjÿubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j Œ refdomain”j Œreftype”Œdoc”Œ refexplicit”ˆŒrefwarn”ˆj&Œ../platform/acpi/hmat”uh1hh³hÇh´Krhj÷ubhŒ— and CDAT information for the CXL nodes. All nodes default to the DRAM tier, unless HMAT/CDAT information is reported to the memory_tier component via ”…””}”(hj÷h²hh³Nh´Nubj )”}”(hŒ`access_coordinates`”h]”hŒaccess_coordinates”…””}”(hj#h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1j hj÷ubhŒ.”…””}”(hj÷h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´Krhj/h²hubhÞ)”}”(hŒXFor more, see :doc:`CXL access coordinates documentation <../linux/access-coordinates>`.”h]”(hŒFor more, see ”…””}”(hj;h²hh³Nh´Nubh)”}”(hŒI:doc:`CXL access coordinates documentation <../linux/access-coordinates>`”h]”j)”}”(hjEh]”hŒ$CXL access coordinates documentation”…””}”(hjGh²hh³Nh´Nubah}”(h]”h ]”(jŒstd”Œstd-doc”eh"]”h$]”h&]”uh1jhjCubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j Œ refdomain”jQŒreftype”Œdoc”Œ refexplicit”ˆŒrefwarn”ˆj&Œ../linux/access-coordinates”uh1hh³hÇh´Kwhj;ubhŒ.”…””}”(hj;h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´Kwhj/h²hubeh}”(h]”Œmemory-tiers-creation”ah ]”h"]”Œmemory tiers creation”ah$]”h&]”uh1hÈhhÊh²hh³hÇh´KbubhÉ)”}”(hhh]”(hÎ)”}”(hŒContiguous Memory Allocation”h]”hŒContiguous Memory Allocation”…””}”(hjxh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÍhjuh²hh³hÇh´K{ubhÞ)”}”(hŒÓThe contiguous memory allocator (CMA) enables reservation of contiguous memory regions on NUMA nodes during early boot. However, CMA cannot reserve memory on NUMA nodes that are not online during early boot. ::”h]”hŒÐThe contiguous memory allocator (CMA) enables reservation of contiguous memory regions on NUMA nodes during early boot. However, CMA cannot reserve memory on NUMA nodes that are not online during early boot.”…””}”(hj†h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K|hjuh²hubjè)”}”(hŒfvoid __init hugetlb_cma_reserve(void) { if (!node_online(nid)) /* do not allow reservations */ }”h]”hŒfvoid __init hugetlb_cma_reserve(void) { if (!node_online(nid)) /* do not allow reservations */ }”…””}”hj”sbah}”(h]”h ]”h"]”h$]”h&]”hÅhÆuh1jçh³hÇh´K€hjuh²hubhÞ)”}”(hXBThis means if users intend to defer management of CXL memory to the driver, CMA cannot be used to guarantee huge page allocations. If enabling CXL memory as SystemRAM in `ZONE_NORMAL` during early boot, CMA reservations per-node can be made with the :code:`cma_pernuma` or :code:`numa_cma` kernel command line parameters.”h]”(hŒ«This means if users intend to defer management of CXL memory to the driver, CMA cannot be used to guarantee huge page allocations. If enabling CXL memory as SystemRAM in ”…””}”(hj¢h²hh³Nh´Nubj )”}”(hŒ `ZONE_NORMAL`”h]”hŒ ZONE_NORMAL”…””}”(hjªh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1j hj¢ubhŒC during early boot, CMA reservations per-node can be made with the ”…””}”(hj¢h²hh³Nh´Nubjf)”}”(hŒ:code:`cma_pernuma`”h]”hŒ cma_pernuma”…””}”(hj¼h²hh³Nh´Nubah}”(h]”h ]”jrah"]”h$]”h&]”Œlanguage”huh1jehj¢ubhŒ or ”…””}”(hj¢h²hh³Nh´Nubjf)”}”(hŒ:code:`numa_cma`”h]”hŒnuma_cma”…””}”(hjÏh²hh³Nh´Nubah}”(h]”h ]”jrah"]”h$]”h&]”Œlanguage”huh1jehj¢ubhŒ kernel command line parameters.”…””}”(hj¢h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÝh³hÇh´K…hjuh²hubeh}”(h]”Œcontiguous-memory-allocation”ah ]”h"]”Œcontiguous memory allocation”ah$]”h&]”uh1hÈhhÊh²hh³hÇh´K{ubeh}”(h]”Œlinux-init-early-boot”ah ]”h"]”Œlinux init (early boot)”ah$]”h&]”uh1hÈhhh²hh³hÇh´Kubeh}”(h]”h ]”h"]”h$]”h&]”Œsource”hÇuh1hŒcurrent_source”NŒ current_line”NŒsettings”Œdocutils.frontend”ŒValues”“”)”}”(hÍNŒ generator”NŒ datestamp”NŒ source_link”NŒ source_url”NŒ toc_backlinks”Œentry”Œfootnote_backlinks”KŒ sectnum_xform”KŒstrip_comments”NŒstrip_elements_with_classes”NŒ strip_classes”NŒ report_level”KŒ halt_level”KŒexit_status_level”KŒdebug”NŒwarning_stream”NŒ traceback”ˆŒinput_encoding”Œ utf-8-sig”Œinput_encoding_error_handler”Œstrict”Œoutput_encoding”Œutf-8”Œoutput_encoding_error_handler”jŒerror_encoding”Œutf-8”Œerror_encoding_error_handler”Œbackslashreplace”Œ language_code”Œen”Œrecord_dependencies”NŒconfig”NŒ id_prefix”hŒauto_id_prefix”Œid”Œ dump_settings”NŒdump_internals”NŒdump_transforms”NŒdump_pseudo_xml”NŒexpose_internals”NŒstrict_visitor”NŒ_disable_config”NŒ_source”hÇŒ _destination”NŒ _config_files”]”Œ7/var/lib/git/docbuild/linux/Documentation/docutils.conf”aŒfile_insertion_enabled”ˆŒ raw_enabled”KŒline_length_limit”M'Œpep_references”NŒ pep_base_url”Œhttps://peps.python.org/”Œpep_file_url_template”Œpep-%04d”Œrfc_references”NŒ rfc_base_url”Œ&https://datatracker.ietf.org/doc/html/”Œ tab_width”KŒtrim_footnote_reference_space”‰Œsyntax_highlight”Œlong”Œ smart_quotes”ˆŒsmartquotes_locales”]”Œcharacter_level_inline_markup”‰Œdoctitle_xform”‰Œ docinfo_xform”KŒsectsubtitle_xform”‰Œ image_loading”Œlink”Œembed_stylesheet”‰Œcloak_email_addresses”ˆŒsection_self_link”‰Œenv”NubŒreporter”NŒindirect_targets”]”Œsubstitution_defs”}”Œsubstitution_names”}”Œrefnames”}”Œrefids”}”Œnameids”}”(jõjòjIjFj»j¸j,j)jrjojíjêuŒ nametypes”}”(jõ‰jI‰j»‰j,‰jr‰jí‰uh}”(jòhÊjFj2j¸jLj)j¾joj/jêjuuŒ footnote_refs”}”Œ citation_refs”}”Œ autofootnotes”]”Œautofootnote_refs”]”Œsymbol_footnotes”]”Œsymbol_footnote_refs”]”Œ footnotes”]”Œ citations”]”Œautofootnote_start”KŒsymbol_footnote_start”KŒ id_counter”Œ collections”ŒCounter”“”}”…”R”Œparse_messages”]”Œtransform_messages”]”Œ transformer”NŒ include_log”]”Œ decoration”Nh²hub.