From bef1014b31c5b33052bcaa865ba3618d73e906f0 Mon Sep 17 00:00:00 2001 From: Joe Hershberger Date: Mon, 4 May 2015 14:55:13 -0500 Subject: net: Implement random ethaddr fallback in eth.c Implement the random ethaddr fallback in eth.c so it is in a common place and not reimplemented in each board or driver that wants this behavior. Signed-off-by: Joe Hershberger Reviewed-by: Simon Glass --- README | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'README') diff --git a/README b/README index 1ea397a35c..5cbb39b93f 100644 --- a/README +++ b/README @@ -5623,7 +5623,8 @@ o If both the SROM and the environment contain a MAC address, and the warning is printed. o If neither SROM nor the environment contain a MAC address, an error - is raised. + is raised. If CONFIG_NET_RANDOM_ETHADDR is defined, then in this case + a random, locally-assigned MAC is used. If Ethernet drivers implement the 'write_hwaddr' function, valid MAC addresses will be programmed into hardware as part of the initialization process. This -- cgit v1.2.1 From 92ac520821405e196c920d60921bdfa5ab6b878c Mon Sep 17 00:00:00 2001 From: Joe Hershberger Date: Mon, 4 May 2015 14:55:14 -0500 Subject: net: Remove all references to CONFIG_ETHADDR and friends We really don't want boards defining fixed MAC addresses in their config so we just remove the option to set it in a fixed way. If you must have a MAC address that was not provisioned, then use the random MAC address functionality. Signed-off-by: Joe Hershberger Reviewed-by: Simon Glass --- README | 16 ++-------------- 1 file changed, 2 insertions(+), 14 deletions(-) (limited to 'README') diff --git a/README b/README index 5cbb39b93f..a1f41f3519 100644 --- a/README +++ b/README @@ -2107,18 +2107,6 @@ CBFS (Coreboot Filesystem) support Some PHY like Intel LXT971A need extra delay after command issued before MII status register can be read -- Ethernet address: - CONFIG_ETHADDR - CONFIG_ETH1ADDR - CONFIG_ETH2ADDR - CONFIG_ETH3ADDR - CONFIG_ETH4ADDR - CONFIG_ETH5ADDR - - Define a default value for Ethernet address to use - for the respective Ethernet interface, in case this - is not determined automatically. - - IP address: CONFIG_IPADDR @@ -2873,8 +2861,8 @@ CBFS (Coreboot Filesystem) support completely disabled. Anybody can change or delete these parameters. - Alternatively, if you #define _both_ CONFIG_ETHADDR - _and_ CONFIG_OVERWRITE_ETHADDR_ONCE, a default + Alternatively, if you define _both_ an ethaddr in the + default env _and_ CONFIG_OVERWRITE_ETHADDR_ONCE, a default Ethernet address is installed in the environment, which can be changed exactly ONCE by the user. [The serial# is unaffected by this, i. e. it remains -- cgit v1.2.1