public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Gregory CLEMENT <gregory.clement@free-electrons.com>
To: Arnd Bergmann <arnd@arndb.de>
Cc: "David S . Miller" <davem@davemloft.net>,
	Marcin Wojtas <mw@semihalf.com>, Evan Wang <xswang@marvell.com>,
	netdev@vger.kernel.org,
	Thomas Petazzoni <thomas.petazzoni@free-electrons.com>,
	Nicolas Schichan <nschichan@freebox.fr>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] bus: mvebu-mbus: use %pad to print phys_addr_t
Date: Tue, 29 Mar 2016 18:04:47 +0200	[thread overview]
Message-ID: <87h9fpw9r4.fsf@free-electrons.com> (raw)
In-Reply-To: <1458036233-2770406-1-git-send-email-arnd@arndb.de> (Arnd Bergmann's message of "Tue, 15 Mar 2016 11:03:39 +0100")

Hi Arnd,
 
 On mar., mars 15 2016, Arnd Bergmann <arnd@arndb.de> wrote:

> A recent change to the mbus driver added a warning printk that
> prints a phys_addr_t using the %x format string, which fails in
> case we build with 64-bit phys_addr_t:
>
> drivers/bus/mvebu-mbus.c: In function 'mvebu_mbus_get_dram_win_info':
> drivers/bus/mvebu-mbus.c:975:9: error: format '%x' expects argument of type 'unsigned int', but argument 2 has type 'phys_addr_t {aka long long unsigned int}' [-Werror=format=]
>
> This uses the special %pa format string instead, so we always
> print the correct type.
>
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> Fixes: f2900acea801 ("bus: mvebu-mbus: provide api for obtaining IO
> and DRAM window information")

What is the status of this patch?

Do you plan to send a second version with the title fixed as suggested
by Joe Perches?

Also do you expect that I collect this patch in the mvebu subsystem?

Thanks,

Gregory

> ---
> The warning was introduced in today's linux-next through the net-next
> tree, please apply this fixup on top.
>
>  drivers/bus/mvebu-mbus.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/bus/mvebu-mbus.c b/drivers/bus/mvebu-mbus.c
> index c2e52864bb03..ce54a0160faa 100644
> --- a/drivers/bus/mvebu-mbus.c
> +++ b/drivers/bus/mvebu-mbus.c
> @@ -972,7 +972,7 @@ int mvebu_mbus_get_dram_win_info(phys_addr_t phyaddr, u8 *target, u8 *attr)
>  		}
>  	}
>  
> -	pr_err("invalid dram address 0x%x\n", phyaddr);
> +	pr_err("invalid dram address %pa\n", &phyaddr);
>  	return -EINVAL;
>  }
>  EXPORT_SYMBOL_GPL(mvebu_mbus_get_dram_win_info);
> -- 
> 2.7.0
>

-- 
Gregory Clement, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com

  parent reply	other threads:[~2016-03-29 16:05 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-03-15 10:03 [PATCH] bus: mvebu-mbus: use %pad to print phys_addr_t Arnd Bergmann
2016-03-15 10:09 ` Joe Perches
2016-03-29 16:04 ` Gregory CLEMENT [this message]
2016-03-29 19:51   ` Arnd Bergmann
2016-03-30  9:37     ` Gregory CLEMENT

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=87h9fpw9r4.fsf@free-electrons.com \
    --to=gregory.clement@free-electrons.com \
    --cc=arnd@arndb.de \
    --cc=davem@davemloft.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mw@semihalf.com \
    --cc=netdev@vger.kernel.org \
    --cc=nschichan@freebox.fr \
    --cc=thomas.petazzoni@free-electrons.com \
    --cc=xswang@marvell.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