Linux 6.0 Continues Plumbing For Compute Express Link (CXL)

Written by Michael Larabel in Hardware on 10 August 2022 at 05:29 AM EDT. 2 Comments
HARDWARE
The Linux kernel continues making preparations around the very exciting Compute Express Link (CXL) thanks to the work of Intel engineers.

The CXL changes were submitted on Tuesday for Linux 6.0. The big CXL feature add this cycle is the initial infrastructure around CXL region provisioning. Dan Williams of Intel sums up the CXL changes for Linux 6.0 as:
...to receive initial support and infrastructure for dynamic CXL region provisioning and other updates. The support is considered "initial" because it only tackles persistent memory provisioning, and only for the decode setup portion of the process.

This is important to merge in this form because it is foundational for other development that depends on the new 'struct cxl_region' object. That follow-on development for features like region assembly from labels, address translation for error handling, and RAM region provisioning will play out over the next several development cycles. Addtionally the recently released CXL 3.0 specification adds more complexity like "dynamic capacity devices" (think "thin provisioning for memory") that builds on top of the 'struct cxl_region' object.

There is new core driver infrastructure to note in this pull. First, alloc_free_mem_region() is introduced as a straightforward enhancement of request_free_mem_region() as a generic allocator of physical memory address space. Recall that CXL provides platform "windows" where CXL regions can be dynamically provisioned, and that provisioning flow needs an allocator. Related to that is the new export of insert_resource_expand_to_fit(), but only into the 'CXL' symbol namespace. That lets the CXL subsystem advertise the platform ranges to exclude from request_free_mem_region() requests. Lastly, there is a new PCI core driver service for DOE (Data Object Exchange) mailboxes. This is a mailbox built over configuration cycles* that has many use cases, one of which is retrieving the CDAT (Coherent Device Attribute Table) from CXL endpoints.

This has appeared in linux-next and has attracted several fixes and cleanups. There is debug in-flight for a recent problem report of configuring 4-way regions under a single host-bridge, but these commits have otherwise passed testing on several emulation platforms including but not limited to QEMU and the in-kernel cxl_test infrastructure. There are no other known issues or conflicts.

The CXL development work continues going along full-speed ahead of next-gen servers beginning to support this cross-vendor industry standard. But as you can see from the patch comments, the Linux CXL support still remains very much a work-in-progress and testing is largely happening thanks to QEMU emulation.

See this pull request for the full list of CXL patches this kernel cycle.
Related News
About The Author
Michael Larabel

Michael Larabel is the principal author of Phoronix.com and founded the site in 2004 with a focus on enriching the Linux hardware experience. Michael has written more than 20,000 articles covering the state of Linux hardware support, Linux performance, graphics drivers, and other topics. Michael is also the lead developer of the Phoronix Test Suite, Phoromatic, and OpenBenchmarking.org automated benchmarking software. He can be followed via Twitter, LinkedIn, or contacted via MichaelLarabel.com.

Popular News This Week