From: Li Ming <ming.li@zohomail.com>
To: dave@stgolabs.net, jonathan.cameron@huawei.com,
dave.jiang@intel.com, alison.schofield@intel.com,
vishal.l.verma@intel.com, ira.weiny@intel.com,
dan.j.williams@intel.com
Cc: linux-cxl@vger.kernel.org, linux-kernel@vger.kernel.org,
Li Ming <ming.li@zohomail.com>
Subject: [PATCH 1/1] cxl/acpi: Fix using extra xormaps for address translation
Date: Thu, 15 Jan 2026 21:16:48 +0800 [thread overview]
Message-ID: <20260115131648.620177-1-ming.li@zohomail.com> (raw)
CXL r3.1 Table 9-22 defines a fixed number of XOR maps for interleave
arithmetic based on the number of interleave ways, as reflected by
hbiw_to_nr_maps[].
The current implementation applies all XOR maps during address
translation, but it should use the spec-defined number of XOR maps
derived from the number of interleave ways.
Fixes: 3b2fedcd75e3 ("cxl: Restore XOR'd position bits during address translation")
Signed-off-by: Li Ming <ming.li@zohomail.com>
---
drivers/cxl/acpi.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/cxl/acpi.c b/drivers/cxl/acpi.c
index 77ac940e3013..5f84d01e7d39 100644
--- a/drivers/cxl/acpi.c
+++ b/drivers/cxl/acpi.c
@@ -61,7 +61,7 @@ u64 cxl_do_xormap_calc(struct cxl_cxims_data *cximsd, u64 addr, int hbiw)
* bits results in val==0, if odd the XOR result is val==1.
*/
- for (int i = 0; i < cximsd->nr_maps; i++) {
+ for (int i = 0; i < nr_maps_to_apply; i++) {
if (!cximsd->xormaps[i])
continue;
pos = __ffs(cximsd->xormaps[i]);
--
2.34.1
next reply other threads:[~2026-01-15 13:17 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-01-15 13:16 Li Ming [this message]
2026-01-15 16:12 ` Dave Jiang
2026-01-15 17:56 ` Alison Schofield
2026-01-16 9:54 ` Li Ming
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260115131648.620177-1-ming.li@zohomail.com \
--to=ming.li@zohomail.com \
--cc=alison.schofield@intel.com \
--cc=dan.j.williams@intel.com \
--cc=dave.jiang@intel.com \
--cc=dave@stgolabs.net \
--cc=ira.weiny@intel.com \
--cc=jonathan.cameron@huawei.com \
--cc=linux-cxl@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=vishal.l.verma@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®