From: santosh.shilimkar@oracle.com (santosh shilimkar)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] soc: TI knav_qmss: fix dma_addr_t printing
Date: Tue, 8 Dec 2015 08:53:53 -0800 [thread overview]
Message-ID: <56670B21.5060209@oracle.com> (raw)
In-Reply-To: <2560281.KhcNzi0XgD@wuerfel>
On 12/8/2015 7:30 AM, Arnd Bergmann wrote:
> The knav_qmss driver is currently broken when CONFIG_LPAE is
> set, which is a bit surprising because I'd expect that any serious
> users of this platforms would have more than 2GB of RAM and require
> LPAE.
>
Well it has been working with LPAE enable always. The production
systems do but IIRC, some of the Eval board were still build with
just 2 GB memory.
> The compiler clearly warns about an incorrect use of dma_addr_t
> in the debug kernel messages:
>
> ti/knav_qmss_queue.c: In function 'knav_queue_setup_region':
> ti/knav_qmss_queue.c:1025:117: warning: format '%x' expects argument of type 'unsigned int', but argument 9 has type 'dma_addr_t {aka long long unsigned int}' [-Wformat=]
> ti/knav_qmss_queue.c:1025:117: warning: format '%x' expects argument of type 'unsigned int', but argument 10 has type 'dma_addr_t {aka long long unsigned int}' [-Wformat=]
> ti/knav_qmss_queue.c: In function 'knav_queue_setup_link_ram':
> ti/knav_qmss_queue.c:1175:118: warning: format '%x' expects argument of type 'unsigned int', but argument 4 has type 'dma_addr_t {aka long long unsigned int}' [-Wformat=]
>
%x should have been %llx or %pad as your patch does now.
> This patch changes all the debugging output to use the correct
> %pad format string that works with both 32-bit and 64-bit dma_addr_t.
> As the variable naming is somewhat confusing here, I also change
> all *_phys names to *_dma when they refer to bus addresses that
> are used for DMA rather than a physical memory address as seen from
> the CPU. This is particularly important on keystone, because the
> two things are not the same there.
>
Right. Rename sounds good.
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---
Thanks for the patch Arnd !!
Wingman/Murali,
Can you guys please test this patch and update the thread ?
I will queue this up for next merge window.
WARNING: multiple messages have this Message-ID (diff)
From: santosh shilimkar <santosh.shilimkar@oracle.com>
To: Arnd Bergmann <arnd@arndb.de>, Murali Karicheri <m-karicheri2@ti.com>
Cc: Santosh Shilimkar <ssantosh@kernel.org>,
linux-kernel@vger.kernel.org,
linux-arm-kernel@lists.infradead.org, "Kwok,
WingMan" <w-kwok2@ti.com>
Subject: Re: [PATCH] soc: TI knav_qmss: fix dma_addr_t printing
Date: Tue, 8 Dec 2015 08:53:53 -0800 [thread overview]
Message-ID: <56670B21.5060209@oracle.com> (raw)
In-Reply-To: <2560281.KhcNzi0XgD@wuerfel>
On 12/8/2015 7:30 AM, Arnd Bergmann wrote:
> The knav_qmss driver is currently broken when CONFIG_LPAE is
> set, which is a bit surprising because I'd expect that any serious
> users of this platforms would have more than 2GB of RAM and require
> LPAE.
>
Well it has been working with LPAE enable always. The production
systems do but IIRC, some of the Eval board were still build with
just 2 GB memory.
> The compiler clearly warns about an incorrect use of dma_addr_t
> in the debug kernel messages:
>
> ti/knav_qmss_queue.c: In function 'knav_queue_setup_region':
> ti/knav_qmss_queue.c:1025:117: warning: format '%x' expects argument of type 'unsigned int', but argument 9 has type 'dma_addr_t {aka long long unsigned int}' [-Wformat=]
> ti/knav_qmss_queue.c:1025:117: warning: format '%x' expects argument of type 'unsigned int', but argument 10 has type 'dma_addr_t {aka long long unsigned int}' [-Wformat=]
> ti/knav_qmss_queue.c: In function 'knav_queue_setup_link_ram':
> ti/knav_qmss_queue.c:1175:118: warning: format '%x' expects argument of type 'unsigned int', but argument 4 has type 'dma_addr_t {aka long long unsigned int}' [-Wformat=]
>
%x should have been %llx or %pad as your patch does now.
> This patch changes all the debugging output to use the correct
> %pad format string that works with both 32-bit and 64-bit dma_addr_t.
> As the variable naming is somewhat confusing here, I also change
> all *_phys names to *_dma when they refer to bus addresses that
> are used for DMA rather than a physical memory address as seen from
> the CPU. This is particularly important on keystone, because the
> two things are not the same there.
>
Right. Rename sounds good.
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---
Thanks for the patch Arnd !!
Wingman/Murali,
Can you guys please test this patch and update the thread ?
I will queue this up for next merge window.
next prev parent reply other threads:[~2015-12-08 16:53 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-12-08 15:30 [PATCH] soc: TI knav_qmss: fix dma_addr_t printing Arnd Bergmann
2015-12-08 15:30 ` Arnd Bergmann
2015-12-08 16:53 ` santosh shilimkar [this message]
2015-12-08 16:53 ` santosh shilimkar
2015-12-08 21:34 ` Arnd Bergmann
2015-12-08 21:34 ` Arnd Bergmann
2015-12-08 22:28 ` santosh shilimkar
2015-12-08 22:28 ` santosh shilimkar
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=56670B21.5060209@oracle.com \
--to=santosh.shilimkar@oracle.com \
--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.