public inbox for netdev@vger.kernel.org
 help / color / mirror / Atom feed
From: Jiri Pirko <jiri@resnulli.us>
To: Stephen Hemminger <stephen@networkplumber.org>
Cc: Shannon Nelson <snelson@pensando.io>,
	netdev@vger.kernel.org, sthemmin@microsoft.com,
	dsahern@gmail.com
Subject: Re: [patch iproute2-next] devlink: introduce -h[ex] cmdline option to allow dumping numbers in hex format
Date: Mon, 25 Apr 2022 11:31:03 +0200	[thread overview]
Message-ID: <YmZqVw/U7UV8kpNI@nanopsycho> (raw)
In-Reply-To: <20220422161054.1db3c836@hermes.local>

Sat, Apr 23, 2022 at 01:10:54AM CEST, stephen@networkplumber.org wrote:
>On Fri, 22 Apr 2022 14:36:21 -0700
>Shannon Nelson <snelson@pensando.io> wrote:
>
>> >   static int fmsg_value_show(struct dl *dl, int type, struct nlattr *nl_data)
>> >   {
>> > +	const char *num_fmt = dl->hex ? "%x" : "%u";
>> > +	const char *num64_fmt = dl->hex ? "%"PRIx64 : "%"PRIu64;  
>> 
>> Can we get a leading "0x" on these to help identify that they are hex 
>> digits?
>
>Yes use %#x

Changed in v2.

  reply	other threads:[~2022-04-25  9:32 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-19 17:16 [patch iproute2-next] devlink: introduce -h[ex] cmdline option to allow dumping numbers in hex format Jiri Pirko
2022-04-22 21:36 ` Shannon Nelson
2022-04-22 23:10   ` Stephen Hemminger
2022-04-25  9:31     ` Jiri Pirko [this message]
2022-04-23  0:20   ` David Ahern
2022-04-25  9:31     ` Jiri Pirko

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=YmZqVw/U7UV8kpNI@nanopsycho \
    --to=jiri@resnulli.us \
    --cc=dsahern@gmail.com \
    --cc=netdev@vger.kernel.org \
    --cc=snelson@pensando.io \
    --cc=stephen@networkplumber.org \
    --cc=sthemmin@microsoft.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