Re: [RFC PATCH v2 06/18] cxl: docs/linux - overview

From: Randy Dunlap
Date: Sat May 10 2025 - 22:06:29 EST




On 4/30/25 11:10 AM, Gregory Price wrote:
> Add type-3 device configuration overview that explains the probe
> process for a type-3 device from early-boot through memory-hotplug.
>
> Signed-off-by: Gregory Price <gourry@xxxxxxxxxx>
> ---
> Documentation/driver-api/cxl/index.rst | 3 +-
> .../driver-api/cxl/linux/overview.rst | 103 ++++++++++++++++++
> 2 files changed, 105 insertions(+), 1 deletion(-)
> create mode 100644 Documentation/driver-api/cxl/linux/overview.rst
>


>
> diff --git a/Documentation/driver-api/cxl/linux/overview.rst b/Documentation/driver-api/cxl/linux/overview.rst
> new file mode 100644
> index 000000000000..f440d79d77d1
> --- /dev/null
> +++ b/Documentation/driver-api/cxl/linux/overview.rst
> @@ -0,0 +1,103 @@
> +.. SPDX-License-Identifier: GPL-2.0
> +
> +========
> +Overview
> +========
> +
> +This section presents the configuration process of a CXL Type-3 memory device,
> +and how it is ultimately exposed to users as either a :code:`DAX` device or
> +normal memory pages via the kernel's page allocator.
> +
> +Portions marked with a bullet are points at which certain kernel objects
> +are generated.
> +
> +1) Early Boot
> +
> + a) BIOS, Build, and Boot Parameters
> +
> + i) EFI_MEMORY_SP
> + ii) CONFIG_EFI_SOFT_RESERVE
> + iii) CONFIG_MHP_DEFAULT_ONLINE_TYPE
> + iv) nosoftreserve
> +
> + b) Memory Map Creation
> +
> + i) EFI Memory Map / E820 Consulted for Soft-Reserved
> +
> + * CXL Memory is set aside to be handled by the CXL driver
> +
> + * Soft-Reserved IO Resource created for CFMWS entry
> +
> + c) NUMA Node Creation
> +
> + * Nodes created from ACPI CEDT CFMWS and SRAT Proximity domains (PXM)
> +
> + d) Memory Tier Creation
> +
> + * A default memory_tier is created with all nodes.
> +
> + e) Contiguous Memory Allocation
> +
> + * Any requested CMA is allocated from Online nodes
> +
> + f) Init Finishes, Drivers start probing
> +
> +2) ACPI and PCI Drivers
> +
> + a) Detects PCI devices is CXL, marking it for probe by CXL driver

device

> +
> +3) CXL Driver Operation


--
~Randy