Skip to content
Commit 08422378 authored by Ben Widawsky's avatar Ben Widawsky Committed by Dan Williams
Browse files

cxl/pci: Add HDM decoder capabilities



An HDM decoder is defined in the CXL 2.0 specification as a mechanism
that allow devices and upstream ports to claim memory address ranges and
participate in interleave sets. HDM decoder registers are within the
component register block defined in CXL 2.0 8.2.3 CXL 2.0 Component
Registers as part of the CXL.cache and CXL.mem subregion.

The Component Register Block is found via the Register Locator DVSEC
in a similar fashion to how the CXL Device Register Block is found. The
primary difference is the capability id size of the Component Register
Block is a single DWORD instead of 4 DWORDS.

It's now possible to configure a CXL type 3 device's HDM decoder. Such
programming is expected for CXL devices with persistent memory, and hot
plugged CXL devices that participate in CXL.mem with volatile memory.

Add probe and mapping functions for the component register blocks.

Reviewed-by: default avatarJonathan Cameron <Jonathan.Cameron@huawei.com>
Co-developed-by: default avatarIra Weiny <ira.weiny@intel.com>
Signed-off-by: default avatarIra Weiny <ira.weiny@intel.com>
Co-developed-by: default avatarVishal Verma <vishal.l.verma@intel.com>
Signed-off-by: default avatarVishal Verma <vishal.l.verma@intel.com>
Signed-off-by: default avatarBen Widawsky <ben.widawsky@intel.com>
Link: https://lore.kernel.org/r/20210528004922.3980613-6-ira.weiny@intel.com
Signed-off-by: default avatarDan Williams <dan.j.williams@intel.com>
parent 9a016527
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment