Browse Source

ARM: orion5x: Use vsprintf %pM extension

Format mac addresses with the normal kernel extension.

Signed-off-by: Joe Perches <joe@perches.com>
Acked-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com>
Joe Perches 10 years ago
parent
commit
7a1436d580
2 changed files with 2 additions and 6 deletions
  1. 1 3
      arch/arm/mach-orion5x/dns323-setup.c
  2. 1 3
      arch/arm/mach-orion5x/tsx09-common.c

+ 1 - 3
arch/arm/mach-orion5x/dns323-setup.c

@@ -236,9 +236,7 @@ static int __init dns323_read_mac_addr(void)
 	}
 
 	iounmap(mac_page);
-	printk("DNS-323: Found ethernet MAC address: ");
-	for (i = 0; i < 6; i++)
-		printk("%.2x%s", addr[i], (i < 5) ? ":" : ".\n");
+	printk("DNS-323: Found ethernet MAC address: %pM\n", addr);
 
 	memcpy(dns323_eth_data.mac_addr, addr, 6);
 

+ 1 - 3
arch/arm/mach-orion5x/tsx09-common.c

@@ -101,9 +101,7 @@ static int __init qnap_tsx09_check_mac_addr(const char *addr_str)
 		addr[i] = byte;
 	}
 
-	printk(KERN_INFO "tsx09: found ethernet mac address ");
-	for (i = 0; i < 6; i++)
-		printk("%.2x%s", addr[i], (i < 5) ? ":" : ".\n");
+	printk(KERN_INFO "tsx09: found ethernet mac address %pM\n", addr);
 
 	memcpy(qnap_tsx09_eth_data.mac_addr, addr, 6);