All of lore.kernel.org
 help / color / mirror / Atom feed
From: rdunlap@infradead.org (Randy Dunlap)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] dma: use %pa to print dma_addr_t
Date: Thu, 12 Sep 2013 10:05:32 -0700	[thread overview]
Message-ID: <5231F45C.3020500@infradead.org> (raw)
In-Reply-To: <1378960710-15648-1-git-send-email-olof@lixom.net>

On 09/11/13 21:38, Olof Johansson wrote:
> This resolves some warnings seen when building with CONFIG_ARM_LPAE=y, since
> dma_addr_t might then be 64-bit:
> 
>   drivers/dma/imx-sdma.c:1092:3: warning: format '%x' expects argument of type 'unsigned int', but argument 6 has type 'dma_addr_t' [-Wformat=]
>   drivers/dma/imx-sdma.c:1166:3: warning: format '%x' expects argument of type 'unsigned int', but argument 6 has type 'dma_addr_t' [-Wformat=]
>   drivers/dma/imx-dma.c:579:3: warning: format '%x' expects argument of type 'unsigned int', but argument 6 has type 'dma_addr_t' [-Wformat=]
>   drivers/dma/imx-dma.c:579:3: warning: format '%x' expects argument of type 'unsigned int', but argument 7 has type 'dma_addr_t' [-Wformat=]
>   drivers/dma/imx-dma.c:593:4: warning: format '%x' expects argument of type 'unsigned int', but argument 9 has type 'dma_addr_t' [-Wformat=]
>   drivers/dma/imx-dma.c:603:4: warning: format '%x' expects argument of type 'unsigned int', but argument 9 has type 'dma_addr_t' [-Wformat=]
>   drivers/dma/imx-dma.c:930:2: warning: format '%x' expects argument of type 'unsigned int', but argument 6 has type 'dma_addr_t' [-Wformat=]
>   drivers/dma/imx-dma.c:930:2: warning: format '%x' expects argument of type 'unsigned int', but argument 7 has type 'dma_addr_t' [-Wformat=]
>   drivers/dma/imx-dma.c:960:2: warning: format '%x' expects argument of type 'unsigned int', but argument 6 has type 'dma_addr_t' [-Wformat=]
>   drivers/dma/imx-dma.c:960:2: warning: format '%x' expects argument of type 'unsigned int', but argument 7 has type 'dma_addr_t' [-Wformat=]
>   drivers/dma/ipu/ipu_idmac.c:1235:2: warning: format '%x' expects argument of type 'unsigned int', but argument 5 has type 'dma_addr_t' [-Wformat=]


I've been tempted to make similar patches, but CONFIG_PHYS_ADDR_T_64BIT
and CONFIG_ARCH_DMA_ADDR_T_64BIT are independent AFAICT,
and %pa is for physical addresses, not necessarily DMA addresses.

Am I confused?


-- 
~Randy

WARNING: multiple messages have this Message-ID (diff)
From: Randy Dunlap <rdunlap@infradead.org>
To: Olof Johansson <olof@lixom.net>
Cc: Dan Williams <dan.j.williams@intel.com>,
	Vinod Koul <vinod.koul@intel.com>,
	Shawn Guo <shawn.guo@linaro.org>,
	linux-kernel@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH] dma: use %pa to print dma_addr_t
Date: Thu, 12 Sep 2013 10:05:32 -0700	[thread overview]
Message-ID: <5231F45C.3020500@infradead.org> (raw)
In-Reply-To: <1378960710-15648-1-git-send-email-olof@lixom.net>

On 09/11/13 21:38, Olof Johansson wrote:
> This resolves some warnings seen when building with CONFIG_ARM_LPAE=y, since
> dma_addr_t might then be 64-bit:
> 
>   drivers/dma/imx-sdma.c:1092:3: warning: format '%x' expects argument of type 'unsigned int', but argument 6 has type 'dma_addr_t' [-Wformat=]
>   drivers/dma/imx-sdma.c:1166:3: warning: format '%x' expects argument of type 'unsigned int', but argument 6 has type 'dma_addr_t' [-Wformat=]
>   drivers/dma/imx-dma.c:579:3: warning: format '%x' expects argument of type 'unsigned int', but argument 6 has type 'dma_addr_t' [-Wformat=]
>   drivers/dma/imx-dma.c:579:3: warning: format '%x' expects argument of type 'unsigned int', but argument 7 has type 'dma_addr_t' [-Wformat=]
>   drivers/dma/imx-dma.c:593:4: warning: format '%x' expects argument of type 'unsigned int', but argument 9 has type 'dma_addr_t' [-Wformat=]
>   drivers/dma/imx-dma.c:603:4: warning: format '%x' expects argument of type 'unsigned int', but argument 9 has type 'dma_addr_t' [-Wformat=]
>   drivers/dma/imx-dma.c:930:2: warning: format '%x' expects argument of type 'unsigned int', but argument 6 has type 'dma_addr_t' [-Wformat=]
>   drivers/dma/imx-dma.c:930:2: warning: format '%x' expects argument of type 'unsigned int', but argument 7 has type 'dma_addr_t' [-Wformat=]
>   drivers/dma/imx-dma.c:960:2: warning: format '%x' expects argument of type 'unsigned int', but argument 6 has type 'dma_addr_t' [-Wformat=]
>   drivers/dma/imx-dma.c:960:2: warning: format '%x' expects argument of type 'unsigned int', but argument 7 has type 'dma_addr_t' [-Wformat=]
>   drivers/dma/ipu/ipu_idmac.c:1235:2: warning: format '%x' expects argument of type 'unsigned int', but argument 5 has type 'dma_addr_t' [-Wformat=]


I've been tempted to make similar patches, but CONFIG_PHYS_ADDR_T_64BIT
and CONFIG_ARCH_DMA_ADDR_T_64BIT are independent AFAICT,
and %pa is for physical addresses, not necessarily DMA addresses.

Am I confused?


-- 
~Randy

  reply	other threads:[~2013-09-12 17:05 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-09-12  4:38 [PATCH] dma: use %pa to print dma_addr_t Olof Johansson
2013-09-12  4:38 ` Olof Johansson
2013-09-12 17:05 ` Randy Dunlap [this message]
2013-09-12 17:05   ` Randy Dunlap
2013-09-12 17:11   ` Olof Johansson
2013-09-12 17:11     ` Olof Johansson
2013-09-12 17:35     ` Russell King - ARM Linux
2013-09-12 17:35       ` Russell King - ARM Linux
2013-09-12 17:45       ` Olof Johansson
2013-09-12 17:45         ` Olof Johansson
2013-09-12 17:44     ` Dan Williams
2013-09-12 17:44       ` Dan Williams
2013-09-12 17:29   ` Joe Perches
2013-09-12 17:29     ` Joe Perches

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=5231F45C.3020500@infradead.org \
    --to=rdunlap@infradead.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.