From: fan <nifan.cxl@gmail.com>
To: Dan Carpenter <dan.carpenter@linaro.org>
Cc: 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>,
Robert Richter <rrichter@amd.com>,
linux-cxl@vger.kernel.org, linux-kernel@vger.kernel.org,
kernel-janitors@vger.kernel.org
Subject: Re: [PATCH] cxl/hdm: Clean up a debug printk
Date: Wed, 7 May 2025 21:53:40 -0700 [thread overview]
Message-ID: <aBw41HRNXEj3tgYG@lg> (raw)
In-Reply-To: <3d3d969d-651d-4e9d-a892-900876a60ab5@moroto.mountain>
On Thu, Feb 22, 2024 at 09:14:02AM +0300, Dan Carpenter wrote:
> Smatch complains that %pa is for phys_addr_t types and "size" is a u64.
>
> drivers/cxl/core/hdm.c:521 cxl_dpa_alloc() error: '%pa' expects
> argument of type 'phys_addr_t*', argument 4 has type 'ullong*
>
> Looking at this, to me it seems more useful to print the sizes as
> decimal instead of hex. Let's do that.
>
> Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
> ---
Reviewed-by: Fan Ni <fan.ni@samsung.com>
> drivers/cxl/core/hdm.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/cxl/core/hdm.c b/drivers/cxl/core/hdm.c
> index 7d97790b893d..0b1843631b26 100644
> --- a/drivers/cxl/core/hdm.c
> +++ b/drivers/cxl/core/hdm.c
> @@ -518,9 +518,9 @@ int cxl_dpa_alloc(struct cxl_endpoint_decoder *cxled, unsigned long long size)
> }
>
> if (size > avail) {
> - dev_dbg(dev, "%pa exceeds available %s capacity: %pa\n", &size,
> + dev_dbg(dev, "%llu exceeds available %s capacity: %llu\n", size,
> cxled->mode == CXL_DECODER_RAM ? "ram" : "pmem",
> - &avail);
> + (u64)avail);
> rc = -ENOSPC;
> goto out;
> }
> --
> 2.43.0
>
next prev parent reply other threads:[~2025-05-08 4:53 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-02-22 6:14 [PATCH] cxl/hdm: Clean up a debug printk Dan Carpenter
2024-02-22 18:29 ` Dave Jiang
2024-02-22 18:51 ` fan
2025-05-08 4:53 ` fan [this message]
2025-05-09 21:01 ` Ira Weiny
2025-05-09 21:08 ` 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=aBw41HRNXEj3tgYG@lg \
--to=nifan.cxl@gmail.com \
--cc=alison.schofield@intel.com \
--cc=dan.carpenter@linaro.org \
--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=kernel-janitors@vger.kernel.org \
--cc=linux-cxl@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--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