From: Joe Perches <joe@perches.com>
To: David Miller <davem@davemloft.net>
Cc: netdev@vger.kernel.org
Subject: Re: sysfs_format_mac
Date: Tue, 16 Jul 2013 13:46:26 -0700 [thread overview]
Message-ID: <1374007586.1949.25.camel@joe-AO722> (raw)
In-Reply-To: <20130716.125641.1190207010366517153.davem@davemloft.net>
On Tue, 2013-07-16 at 12:56 -0700, David Miller wrote:
>
> I assume that the only reason sysfs_format_mac() exists at all, and
> don't just use scnprintf() calls with "%pm\n", is that some devices
> have MAC addresses which are not 6 bytes in length.
>
> But it's such a waste to have this special case piece of code
> just for that.
>
> It would make so much more sense to allow specifying a length
> specifier to %pm and friends.
scnprintf("%*ph", (int)size, buffer)
next prev parent reply other threads:[~2013-07-16 20:46 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-07-16 19:56 sysfs_format_mac David Miller
2013-07-16 20:46 ` Joe Perches [this message]
2013-07-16 20:58 ` sysfs_format_mac David Miller
2013-07-16 21:12 ` sysfs_format_mac Joe Perches
2013-07-16 23:25 ` sysfs_format_mac David Miller
2013-07-16 23:32 ` sysfs_format_mac Joe Perches
2013-07-16 23:41 ` sysfs_format_mac David Miller
2013-07-17 0:10 ` sysfs_format_mac David Miller
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=1374007586.1949.25.camel@joe-AO722 \
--to=joe@perches.com \
--cc=davem@davemloft.net \
--cc=netdev@vger.kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox