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

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



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


[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux