Linux CXL
 help / color / mirror / Atom feed
From: Arnd Bergmann <arnd@kernel.org>
To: Davidlohr Bueso <dave@stgolabs.net>,
	Jonathan Cameron <jonathan.cameron@huawei.com>,
	Dave Jiang <dave.jiang@intel.com>,
	Alison Schofield <alison.schofield@intel.com>,
	Vishal Verma <vishal.l.verma@intel.com>,
	Ira Weiny <ira.weiny@intel.com>,
	Dan Williams <dan.j.williams@intel.com>,
	Ben Cheatham <benjamin.cheatham@amd.com>
Cc: Arnd Bergmann <arnd@arndb.de>, Gregory Price <gourry@gourry.net>,
	Robert Richter <rrichter@amd.com>, Li Ming <ming.li@zohomail.com>,
	linux-cxl@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: [PATCH] cxl/region: fix format string for resource_size_t
Date: Thu,  4 Dec 2025 10:52:26 +0100	[thread overview]
Message-ID: <20251204095237.1032528-1-arnd@kernel.org> (raw)

From: Arnd Bergmann <arnd@arndb.de>

The size of this type is architecture specific, and the recommended
way to print it portably is through the custom %pap format string.

Fixes: d6602e25819d ("cxl/region: Add support to indicate region has extended linear cache")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 drivers/cxl/core/region.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/cxl/core/region.c b/drivers/cxl/core/region.c
index ae899f68551f..fc36a5413d3f 100644
--- a/drivers/cxl/core/region.c
+++ b/drivers/cxl/core/region.c
@@ -759,7 +759,7 @@ static ssize_t extended_linear_cache_size_show(struct device *dev,
 	ACQUIRE(rwsem_read_intr, rwsem)(&cxl_rwsem.region);
 	if ((rc = ACQUIRE_ERR(rwsem_read_intr, &rwsem)))
 		return rc;
-	return sysfs_emit(buf, "%#llx\n", p->cache_size);
+	return sysfs_emit(buf, "%pap\n", &p->cache_size);
 }
 static DEVICE_ATTR_RO(extended_linear_cache_size);
 
-- 
2.39.5


             reply	other threads:[~2025-12-04  9:52 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-12-04  9:52 Arnd Bergmann [this message]
2025-12-04 15:22 ` [PATCH] cxl/region: fix format string for resource_size_t Dave Jiang
2026-01-05 22:17 ` Ira Weiny
2026-01-05 23:06 ` Alison Schofield
2026-01-06  1:13 ` Dave Jiang

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=20251204095237.1032528-1-arnd@kernel.org \
    --to=arnd@kernel.org \
    --cc=alison.schofield@intel.com \
    --cc=arnd@arndb.de \
    --cc=benjamin.cheatham@amd.com \
    --cc=dan.j.williams@intel.com \
    --cc=dave.jiang@intel.com \
    --cc=dave@stgolabs.net \
    --cc=gourry@gourry.net \
    --cc=ira.weiny@intel.com \
    --cc=jonathan.cameron@huawei.com \
    --cc=linux-cxl@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=ming.li@zohomail.com \
    --cc=rrichter@amd.com \
    --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