public inbox for dmaengine@vger.kernel.org
 help / color / mirror / Atom feed
From: Bjorn Andersson <bjorn.andersson@linaro.org>
To: Xiaoming Ni <nixiaoming@huawei.com>
Cc: vkoul@kernel.org, dmaengine@vger.kernel.org,
	linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org,
	agross@kernel.org, wangle6@huawei.com
Subject: Re: [PATCH] dma/qcom/gpi: Fixes a format mismatch
Date: Sun, 20 Dec 2020 19:51:20 -0800	[thread overview]
Message-ID: <X+AbuEhwExGxrkax@ripper> (raw)
In-Reply-To: <20201218104137.59200-1-nixiaoming@huawei.com>

On Fri 18 Dec 02:41 PST 2020, Xiaoming Ni wrote:

> drivers/dma/qcom/gpi.c:1419:3: warning: format '%lu' expects argument of
>  type 'long unsigned int', but argument 8 has type 'size_t {aka unsigned
>  int}' [-Wformat=]
> drivers/dma/qcom/gpi.c:1427:31: warning: format '%lu' expects argument of
>  type 'long unsigned int', but argument 3 has type 'size_t {aka unsigned
>  int}' [-Wformat=]
> drivers/dma/qcom/gpi.c:1447:3: warning: format '%llx' expects argument of
>  type 'long long unsigned int', but argument 4 has type 'dma_addr_t {aka
>  unsigned int}' [-Wformat=]
> drivers/dma/qcom/gpi.c:1447:3: warning: format '%llx' expects argument of
>  type 'long long unsigned int', but argument 5 has type 'phys_addr_t {aka
>  unsigned int}' [-Wformat=]
> 

Reviewed-by: Bjorn Andersson <bjorn.andersson@linaro.org>

> Signed-off-by: Xiaoming Ni <nixiaoming@huawei.com>
> ---
>  drivers/dma/qcom/gpi.c | 8 ++++----
>  1 file changed, 4 insertions(+), 4 deletions(-)
> 
> diff --git a/drivers/dma/qcom/gpi.c b/drivers/dma/qcom/gpi.c
> index d2334f535de2..556c070a514c 100644
> --- a/drivers/dma/qcom/gpi.c
> +++ b/drivers/dma/qcom/gpi.c
> @@ -1416,7 +1416,7 @@ static int gpi_alloc_ring(struct gpi_ring *ring, u32 elements,
>  	len = 1 << bit;
>  	ring->alloc_size = (len + (len - 1));
>  	dev_dbg(gpii->gpi_dev->dev,
> -		"#el:%u el_size:%u len:%u actual_len:%llu alloc_size:%lu\n",
> +		"#el:%u el_size:%u len:%u actual_len:%llu alloc_size:%zu\n",
>  		  elements, el_size, (elements * el_size), len,
>  		  ring->alloc_size);
>  
> @@ -1424,7 +1424,7 @@ static int gpi_alloc_ring(struct gpi_ring *ring, u32 elements,
>  					       ring->alloc_size,
>  					       &ring->dma_handle, GFP_KERNEL);
>  	if (!ring->pre_aligned) {
> -		dev_err(gpii->gpi_dev->dev, "could not alloc size:%lu mem for ring\n",
> +		dev_err(gpii->gpi_dev->dev, "could not alloc size:%zu mem for ring\n",
>  			ring->alloc_size);
>  		return -ENOMEM;
>  	}
> @@ -1444,8 +1444,8 @@ static int gpi_alloc_ring(struct gpi_ring *ring, u32 elements,
>  	smp_wmb();
>  
>  	dev_dbg(gpii->gpi_dev->dev,
> -		"phy_pre:0x%0llx phy_alig:0x%0llx len:%u el_size:%u elements:%u\n",
> -		ring->dma_handle, ring->phys_addr, ring->len,
> +		"phy_pre:%pad phy_alig:%pa len:%u el_size:%u elements:%u\n",
> +		&ring->dma_handle, &ring->phys_addr, ring->len,
>  		ring->el_size, ring->elements);
>  
>  	return 0;
> -- 
> 2.27.0
> 

  reply	other threads:[~2020-12-21  4:56 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-12-18 10:41 [PATCH] dma/qcom/gpi: Fixes a format mismatch Xiaoming Ni
2020-12-21  3:51 ` Bjorn Andersson [this message]
2020-12-21 14:10 ` Vinod Koul

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=X+AbuEhwExGxrkax@ripper \
    --to=bjorn.andersson@linaro.org \
    --cc=agross@kernel.org \
    --cc=dmaengine@vger.kernel.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=nixiaoming@huawei.com \
    --cc=vkoul@kernel.org \
    --cc=wangle6@huawei.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