staging: most: Use %pM format specifier for MAC addresses
Convert to %pM instead of using custom code. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://lore.kernel.org/r/20200730151506.38827-1-andriy.shevchenko@linux.intel.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
536a4f75d4
commit
11c416e3f0
|
@ -564,13 +564,11 @@ static void on_netinfo(struct most_interface *iface,
|
|||
|
||||
if (m && is_valid_ether_addr(m)) {
|
||||
if (!is_valid_ether_addr(dev->dev_addr)) {
|
||||
netdev_info(dev, "set mac %02x-%02x-%02x-%02x-%02x-%02x\n",
|
||||
m[0], m[1], m[2], m[3], m[4], m[5]);
|
||||
netdev_info(dev, "set mac %pM\n", m);
|
||||
ether_addr_copy(dev->dev_addr, m);
|
||||
netif_dormant_off(dev);
|
||||
} else if (!ether_addr_equal(dev->dev_addr, m)) {
|
||||
netdev_warn(dev, "reject mac %02x-%02x-%02x-%02x-%02x-%02x\n",
|
||||
m[0], m[1], m[2], m[3], m[4], m[5]);
|
||||
netdev_warn(dev, "reject mac %pM\n", m);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user