summaryrefslogtreecommitdiffstats
path: root/arch/sandbox/board
diff options
context:
space:
mode:
authorAhmad Fatoum <a.fatoum@pengutronix.de>2021-06-19 05:45:15 +0200
committerSascha Hauer <s.hauer@pengutronix.de>2021-06-22 07:13:41 +0200
commitd4efa05303408d84a347c1c560ea860cf9ad953c (patch)
treec4aa1112a41f36fa45414420210516b31ea708c1 /arch/sandbox/board
parent63fd2b318ea3866c46bd4f85b4a64a269512db35 (diff)
downloadbarebox-d4efa05303408d84a347c1c560ea860cf9ad953c.tar.gz
barebox-d4efa05303408d84a347c1c560ea860cf9ad953c.tar.xz
net: consult device tree for ethernet address in NVMEM as fall-back
While barebox fixes up the mac-address into the device tree, it doesn't care much for extracting a mac address _from_ the device tree, whether it be from local-mac-address property or from a mac-address nvmem cell. Fix the latter by calling of_get_mac_addr_nvmem for each Ethernet adapter. We do this in a very late initcall, because we don't want to enforce a probe a probe order between nvmem providers and network devices. We can't do it at randomization time, because we need to fixup Ethernet mac addresses, even when barebox itself doesn't ifup the netdev. of_get_mac_addr_nvmem could be replaced by of_get_mac_address to also parse local-mac-address and brethern, but justifying this change is left as a future exercise. Cc: Michael Grzeschik <m.grzeschik@pengutronix.de> Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20210619034516.6737-13-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'arch/sandbox/board')
0 files changed, 0 insertions, 0 deletions