Re: [PATCH v2] arch/mips rb532: replace mac_addr parsing

James Hogan
2014-06-24T10:13:38Z

Hi Daniel,

On 24/06/14 09:45, Daniel Walter wrote:
> @@ -333,7 +311,13 @@ static int __init plat_setup_devices(void)
> static int __init setup_kmac(char *s)
> {
> printk(KERN_INFO "korina mac = %s\n", s);
> - parse_mac_addr(s);
> + sscanf(s, "%hhx:%hhx:%hhx:%hhx:%hhx:%hhx",
> + &korina_dev0_data.mac[0],
> + &korina_dev0_data.mac[1],
> + &korina_dev0_data.mac[2],
> + &korina_dev0_data.mac[3],
> + &korina_dev0_data.mac[4],
> + &korina_dev0_data.mac[5]);

Does it make sense to go one better and use mac_pton() for this?

Cheers
James