[PATCH v5 3/5] net: of_net: Derive MAC addresses from a unique device ID

Andrew Lunn andrew at lunn.ch
Mon Nov 30 17:30:53 PST 2026


> @@ -142,7 +239,11 @@ int of_get_mac_address(struct device_node *np, u8 *addr)
>  	if (!ret)
>  		return 0;
>  
> -	return of_get_mac_address_nvmem(np, addr);
> +	ret = of_get_mac_address_nvmem(np, addr);
> +	if (!ret || ret == -EPROBE_DEFER)
> +		return ret;

You need to be careful here. There might be devices which currently
work because they return EPROBE_DEFER here and try again later.

Also, none of the other sources of the MAC address in this function
special case it.


    Andrew

---
pw-bot: cr



More information about the Linux-rockchip mailing list