Linux 7.5 Whitelisting Intel Xeon Server CPUs For Peer-To-Peer DMA "P2PDMA"

For those making use of VMware virtualization or other scenarios, the upcoming Linux 7.5 kernel will see that peer-to-peer DMA "P2PDMA" is properly enabled for modern Intel Xeon servers. This follows a similar change already in place for AMD Zen-based platforms to ensure P2PDMA usage is properly whitelisted. Enabling P2PDMA requires a shared upstream bridge or a host bridge matching the PCI(e) P2PDMA whitelist. In cases like VMware VMs, the passthrough devices appear without the host bridge devices and in turn can lead to P2PDMA not being exposed. Thus for Linux 7.5, Intel Xeon server CPUs going back to Skylake and heading through next-generation Diamond Rapids processors are now being explicitly whitelisted so that P2PDMA will be advertised. PCIe P2PDMA is important for performance reasons to allow transferring data from one PCIe device to another without going through the host system RAM. Intel software engineer Pavel Popov explained with the pending Linux kernel patch: "Peer-to-Peer DMA (P2PDMA) between two devices requires either a shared upstream bridge or a host bridge matching pci_p2pdma_whitelist[]. In VMware guests, passthrough devices appear directly on virtual root buses without host bridge devices. In Hyper-V guests, each passthrough device appears in a PCI domain of its own without a host bridge device. Consequently, P2PDMA checks evaluate endpoint Device IDs against the host bridge whitelist, causing P2PDMA requests to fail regardless of host support. This affects discrete devices such as GPUs, NICs and NVMe drives. Add an explicit list of the Intel Xeon server generations from Skylake-SP to Diamond Rapids to cpu_supports_p2pdma(). These are the CPUs whose host bridges are in pci_p2pdma_whitelist[] without restrictions. AMD Zen and newer are already covered by cpu_supports_p2pdma(), so only Intel entries are needed. Tested with the Intel Level Zero P2P benchmark (ze_peer) on Arc Pro B60 cards in a Linux guest on VMware ESXi 9.0 (Emerald Rapids host)." The patch is queued into the PCI subsystem's "next" GIt branch and thus slated for inclusion in Linux 7.5 for seeing that PCIe P2PDMA is always working across Skylake, Icelake, Sapphire Rapids, Emerald Rapids, Granite Rapids, and Diamond Rapids servers. The Linux 7.5 merge window is set to open around late December while it will then debut as stable in Q1 as the first major Linux kernel release of 2027.

Original Source

Read the full article at Phoronix →

KhanList aggregates and links to publicly available news content. We do not host full articles from third-party sources. Always verify important information with original sources.