[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250320180450.539-3-shiju.jose@huawei.com>
Date: Thu, 20 Mar 2025 18:04:39 +0000
From: <shiju.jose@...wei.com>
To: <linux-cxl@...r.kernel.org>, <dan.j.williams@...el.com>,
<dave@...olabs.net>, <jonathan.cameron@...wei.com>, <dave.jiang@...el.com>,
<alison.schofield@...el.com>, <vishal.l.verma@...el.com>,
<ira.weiny@...el.com>, <david@...hat.com>, <Vilas.Sridharan@....com>
CC: <linux-edac@...r.kernel.org>, <linux-acpi@...r.kernel.org>,
<linux-mm@...ck.org>, <linux-kernel@...r.kernel.org>, <bp@...en8.de>,
<tony.luck@...el.com>, <rafael@...nel.org>, <lenb@...nel.org>,
<mchehab@...nel.org>, <leo.duran@....com>, <Yazen.Ghannam@....com>,
<rientjes@...gle.com>, <jiaqiyan@...gle.com>, <Jon.Grimm@....com>,
<dave.hansen@...ux.intel.com>, <naoya.horiguchi@....com>,
<james.morse@....com>, <jthoughton@...gle.com>, <somasundaram.a@....com>,
<erdemaktas@...gle.com>, <pgonda@...gle.com>, <duenwen@...gle.com>,
<gthelen@...gle.com>, <wschwartz@...erecomputing.com>,
<dferguson@...erecomputing.com>, <wbs@...amperecomputing.com>,
<nifan.cxl@...il.com>, <yazen.ghannam@....com>, <tanxiaofei@...wei.com>,
<prime.zeng@...ilicon.com>, <roberto.sassu@...wei.com>,
<kangkang.shen@...urewei.com>, <wanghuiqiang@...wei.com>,
<linuxarm@...wei.com>, <shiju.jose@...wei.com>
Subject: [PATCH v2 2/8] EDAC: Update documentation for the CXL memory patrol scrub control feature
From: Shiju Jose <shiju.jose@...wei.com>
Update the Documentation/edac/scrub.rst to include descriptions and
policies for CXL memory device-based and CXL region-based patrol scrub
control.
Note: This may require inputs from CXL memory experts regarding
region-based scrubbing policies.
Signed-off-by: Shiju Jose <shiju.jose@...wei.com>
---
Documentation/edac/scrub.rst | 47 ++++++++++++++++++++++++++++++++++++
1 file changed, 47 insertions(+)
diff --git a/Documentation/edac/scrub.rst b/Documentation/edac/scrub.rst
index daab929cdba1..d1c02bd90090 100644
--- a/Documentation/edac/scrub.rst
+++ b/Documentation/edac/scrub.rst
@@ -264,3 +264,51 @@ Sysfs files are documented in
`Documentation/ABI/testing/sysfs-edac-scrub`
`Documentation/ABI/testing/sysfs-edac-ecs`
+
+Examples
+--------
+
+The usage takes the form shown in these examples:
+
+1. CXL memory device patrol scrubber
+
+1.1 Device based scrubbing
+
+CXL memory is exposed to memory management subsystem and ultimately userspace
+via CXL devices.
+
+For cases where hardware interleave controls do not directly map to regions of
+Physical Address space, perhaps due to interleave the approach described inĀ
+1.2 Region based scrubbing section, which is specific to CXL regions should be
+followed. In those cases settings on the presented interface may interact with
+direct control via a device instance specific interface and care must be taken.
+
+Sysfs files for scrubbing are documented in
+`Documentation/ABI/testing/sysfs-edac-scrub`
+
+1.2. Region based scrubbing
+
+CXL memory is exposed to memory management subsystem and ultimately userspace
+via CXL regions. CXL Regions represent mapped memory capacity in system
+physical address space. These can incorporate one or more parts of multiple CXL
+memory devices with traffic interleaved across them. The user may want to control
+the scrub rate via this more abstract region instead of having to figure out the
+constituent devices and program them separately. The scrub rate for each device
+covers the whole device. Thus if multiple regions use parts of that device then
+requests for scrubbing of other regions may result in a higher scrub rate than
+requested for this specific region.
+
+1. When user sets scrub rate for a memory region, the scrub rate for all the CXL
+ memory devices interleaved under that region is updated with the same scrub
+ rate.
+
+2. When user sets scrub rate for a memory device, only the scrub rate for that
+ memory devices is updated though device may be part of a memory region and
+ does not change scrub rate of other memory devices of that memory region.
+
+3. Scrub rate of a CXL memory device may be set via EDAC device or region scrub
+ interface simultaneously. Care must be taken to prevent a race condition, or
+ only region-based setting may be allowed.
+
+Sysfs files for scrubbing are documented in
+`Documentation/ABI/testing/sysfs-edac-scrub`
--
2.43.0
Powered by blists - more mailing lists