mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Sascha Hauer <s.hauer@pengutronix.de>
To: Teresa Remmet <t.remmet@phytec.de>
Cc: barebox@lists.infradead.org
Subject: Re: [PATCH] mtd: core: Fix printing partitions in hex
Date: Thu, 7 Jun 2018 09:21:11 +0200	[thread overview]
Message-ID: <20180607072111.v4z6g3gfnaw36ms5@pengutronix.de> (raw)
In-Reply-To: <1528284502-39491-1-git-send-email-t.remmet@phytec.de>

On Wed, Jun 06, 2018 at 01:28:22PM +0200, Teresa Remmet wrote:
> When printing the partition size with "0x" prefix the value has to
> be displayed in hex.
> 
> Signed-off-by: Teresa Remmet <t.remmet@phytec.de>
> ---
>  drivers/mtd/core.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

Applied, thanks

Sascha

> 
> diff --git a/drivers/mtd/core.c b/drivers/mtd/core.c
> index d2012b5f70d6..ae7818a189d7 100644
> --- a/drivers/mtd/core.c
> +++ b/drivers/mtd/core.c
> @@ -473,7 +473,7 @@ static char *print_size(uint64_t s)
>  		return basprintf("%lldM", s >> 20);
>  	if (!(s & ((1 << 10) - 1)))
>  		return basprintf("%lldk", s >> 10);
> -	return basprintf("0x%lld", s);
> +	return basprintf("0x%llx", s);
>  }
>  
>  static int print_part(char *buf, int bufsize, struct mtd_info *mtd, uint64_t last_ofs,
> -- 
> 2.7.4
> 
> 
> _______________________________________________
> barebox mailing list
> barebox@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/barebox
> 

-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

      reply	other threads:[~2018-06-07  7:21 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-06-06 11:28 Teresa Remmet
2018-06-07  7:21 ` Sascha Hauer [this message]

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=20180607072111.v4z6g3gfnaw36ms5@pengutronix.de \
    --to=s.hauer@pengutronix.de \
    --cc=barebox@lists.infradead.org \
    --cc=t.remmet@phytec.de \
    /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