public inbox for nvdimm@lists.linux.dev
 help / color / mirror / Atom feed
From: Dave Jiang <dave.jiang@intel.com>
To: linux-cxl@vger.kernel.org, nvdimm@lists.linux.dev
Cc: alison.schofield@intel.com
Subject: [NDCTL PATCH] cxl: Add support for updated CXL provider name
Date: Wed,  4 Feb 2026 17:29:24 -0700	[thread overview]
Message-ID: <20260205002924.1831038-1-dave.jiang@intel.com> (raw)

With a 7.1 kernel, the CXL provider name is changed due to removal of the
nvdimm_bus_register() wrapper function in cxl_test. This impacts the
security unit tests. Update to address the change.

Signed-off-by: Dave Jiang <dave.jiang@intel.com>
---
 test/common       | 6 ++++++
 test/cxl-security | 6 +++---
 test/security.sh  | 2 +-
 3 files changed, 10 insertions(+), 4 deletions(-)

diff --git a/test/common b/test/common
index 2d076402ef7c..f9d180ac5bd3 100644
--- a/test/common
+++ b/test/common
@@ -156,3 +156,9 @@ check_dmesg()
 
 # CXL COMMON
 CXL_TEST_QOS_CLASS=42
+
+if check_min_kver "7.1"; then
+	CXL_TEST_PROVIDER="cxl_acpi.0"
+else
+	CXL_TEST_PROVIDER="cxl_test"
+fi
diff --git a/test/cxl-security b/test/cxl-security
index 9a28ffd82b0b..11301fbc5f1b 100644
--- a/test/cxl-security
+++ b/test/cxl-security
@@ -3,9 +3,9 @@
 
 detect()
 {
-	dev="$($NDCTL list -b "$CXL_TEST_BUS" -D | jq -r 'sort_by(.id) | .[0].dev')"
+	dev="$($NDCTL list -b "$CXL_TEST_PROVIDER" -D | jq -r 'sort_by(.id) | .[0].dev')"
 	[ -n "$dev" ] || err "$LINENO"
-	id="$($NDCTL list -b "$CXL_TEST_BUS" -D | jq -r 'sort_by(.id) | .[0].id')"
+	id="$($NDCTL list -b "$CXL_TEST_PROVIDER" -D | jq -r 'sort_by(.id) | .[0].id')"
 	[ -n "$id" ] || err "$LINENO"
 }
 
@@ -20,7 +20,7 @@ lock_dimm()
 	test -e "$bus_provider_path" || err "$LINENO"
 	bus_provider=$(cat ${bus_provider_path})
 
-	[[ "$bus_provider" == "$CXL_TEST_BUS" ]] || err "$LINENO"
+	[[ "$bus_provider" == "$CXL_TEST_PROVIDER" ]] || err "$LINENO"
 	bus="cxl"
 	nmem_provider_path="/sys/bus/nd/devices/${dev}/${bus}/provider"
 	nmem_provider=$(cat ${nmem_provider_path})
diff --git a/test/security.sh b/test/security.sh
index d3a840c23276..ee27df215edd 100755
--- a/test/security.sh
+++ b/test/security.sh
@@ -212,7 +212,7 @@ if [ "$1" = "nfit" ]; then
 	KMOD_TEST="nfit_test"
 elif [ "$1" = "cxl" ]; then
 	. $(dirname $0)/cxl-security
-	TEST_BUS="$CXL_TEST_BUS"
+	TEST_BUS="$CXL_TEST_PROVIDER"
 	check_min_kver "6.2" || do_skip "may lack security handling"
 	KMOD_TEST="cxl_test"
 else

base-commit: 39085f76b6a9d3ac349c3c5dab1cb820c86a293d
-- 
2.52.0


                 reply	other threads:[~2026-02-05  0:29 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=20260205002924.1831038-1-dave.jiang@intel.com \
    --to=dave.jiang@intel.com \
    --cc=alison.schofield@intel.com \
    --cc=linux-cxl@vger.kernel.org \
    --cc=nvdimm@lists.linux.dev \
    /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