Re: [RFC PATCHv2] printk: add the %pM, %p4, %p6 format specifiers

From: Johannes Berg
Date: Mon Oct 27 2008 - 03:00:00 EST


On Sun, 2008-10-26 at 17:31 -0700, Harvey Harrison wrote:
> Add format specifiers for printing out colon-separated bytes:
>
> MAC addresses (%pM):
> xx:xx:xx:xx:xx:xx
>
> IPv4 addresses (%p4):
> xx:xx:xx:xx

As hpa points out, the usual notation would be %d.%d.%d.%d :)

> %#pM, %#p4, %#p6 are also supported and print without the colon
> separators.

The # for ipv4 we might use for cpu-endian rather than network-endian
maybe?

Also can you keep mac/ip address patches split up so we can use my
version of the mac address patch (it's already well-tested)?

johannes

Attachment: signature.asc
Description: This is a digitally signed message part