]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
Convert CONFIG_OVERWRITE_ETHADDR_ONCE to Kconfig
authorTom Rini <trini@konsulko.com>
Fri, 2 Dec 2022 21:42:39 +0000 (16:42 -0500)
committerTom Rini <trini@konsulko.com>
Thu, 22 Dec 2022 15:31:48 +0000 (10:31 -0500)
This converts the following to Kconfig:
   CONFIG_OVERWRITE_ETHADDR_ONCE

Signed-off-by: Tom Rini <trini@konsulko.com>
README
configs/M5253DEMO_defconfig
configs/M5275EVB_defconfig
configs/eb_cpu5282_defconfig
configs/eb_cpu5282_internal_defconfig
env/Kconfig
include/configs/M5253DEMO.h
include/configs/M5275EVB.h
include/configs/eb_cpu5282.h

diff --git a/README b/README
index 9e2627863ce587d7f5017be72f4d67f3b63a6236..3ebee1cb3755a5b0fdba3a6a939686b3c4d16707 100644 (file)
--- a/README
+++ b/README
@@ -1071,13 +1071,6 @@ The following options need to be configured:
                completely disabled. Anybody can change or delete
                these parameters.
 
-               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
-               read-only.]
-
                The same can be accomplished in a more flexible way
                for any variable by configuring the type of access
                to allow for those variables in the ".flags" variable
index 4de6290b7d31c2d0c2a6e0e3e1a31958b27efef1..ea079972c9bcdd7a22c2db76faccdc637488b677 100644 (file)
@@ -25,6 +25,7 @@ CONFIG_CMD_CACHE=y
 CONFIG_CMD_EXT2=y
 CONFIG_CMD_FAT=y
 CONFIG_MAC_PARTITION=y
+CONFIG_OVERWRITE_ETHADDR_ONCE=y
 CONFIG_SYS_RELOC_GD_ENV_ADDR=y
 CONFIG_USE_HOSTNAME=y
 CONFIG_HOSTNAME="M5253DEMO"
index 01961e5ae27fcb6928a444fca0fb0634e6115105..d84d9d98c5ac2a3e54570aca6e30d8de6f1d523b 100644 (file)
@@ -31,6 +31,7 @@ CONFIG_CMD_MII=y
 CONFIG_MII_INIT=y
 CONFIG_CMD_PING=y
 CONFIG_CMD_CACHE=y
+CONFIG_OVERWRITE_ETHADDR_ONCE=y
 CONFIG_SYS_RELOC_GD_ENV_ADDR=y
 CONFIG_SYS_FAULT_ECHO_LINK_DOWN=y
 CONFIG_SYS_RX_ETH_BUFFER=8
index a831c1c5d2aae363ab6b7c86751369e1599d3395..7304b4938725df09cde37a83f60c19cab935b7c2 100644 (file)
@@ -32,6 +32,7 @@ CONFIG_BOOTP_BOOTFILESIZE=y
 CONFIG_CMD_MII=y
 CONFIG_MII_INIT=y
 CONFIG_CMD_DATE=y
+CONFIG_OVERWRITE_ETHADDR_ONCE=y
 CONFIG_SYS_FAULT_ECHO_LINK_DOWN=y
 CONFIG_SYS_RX_ETH_BUFFER=8
 CONFIG_SYS_I2C_LEGACY=y
index 6a673c9181104c79ba9239f280625cfa832b5cf6..5ecdda418aad0cb8570e0762e573bcb2d8d75cf6 100644 (file)
@@ -30,6 +30,7 @@ CONFIG_BOOTP_BOOTFILESIZE=y
 CONFIG_CMD_MII=y
 CONFIG_MII_INIT=y
 CONFIG_CMD_DATE=y
+CONFIG_OVERWRITE_ETHADDR_ONCE=y
 CONFIG_SYS_FAULT_ECHO_LINK_DOWN=y
 CONFIG_SYS_RX_ETH_BUFFER=8
 CONFIG_SYS_I2C_LEGACY=y
index c28d9e89f68bc76abdde6fc78585034769e47e4a..7ca992aa1d4032d58b1652e19776116cd9e3e61d 100644 (file)
@@ -30,6 +30,15 @@ config ENV_OVERWRITE
          Use this to permit overriding of certain environmental variables
          like Ethernet and Serial
 
+config OVERWRITE_ETHADDR_ONCE
+       bool "Enable overwriting ethaddr environment variables once"
+       depends on !ENV_OVERWRITE
+       help
+         Enable this to allow for the ethaddr environment variables to be
+         overwritten one time per boot, only. This allows for a default
+         to be installed in the environment, which can be changed exactly ONCE
+         by the user.
+
 config ENV_MIN_ENTRIES
        int "Minimum number of entries in the environment hashtable"
        default 64
index 65a7aa04086e98296846701788eb608c77d24a81..bc156df20d514e5fc41eec3d0b980ea58bb07a8b 100644 (file)
@@ -20,8 +20,6 @@
        env/embedded.o(.text*);
 
 #ifdef CONFIG_DRIVER_DM9000
-#      define CONFIG_OVERWRITE_ETHADDR_ONCE
-
 #      define CONFIG_EXTRA_ENV_SETTINGS                \
                "netdev=eth0\0"                         \
                "inpclk=" __stringify(CONFIG_SYS_INPUT_CLKSRC) "\0"     \
index ff9f85358963b16fbf4253c6050a832d050cc1bf..41974cff410da71a1045b8be5f637c524982f0c3 100644 (file)
 #define CFG_SYS_I2C_PINMUX_CLR (0xFFF0)
 #define CFG_SYS_I2C_PINMUX_SET (0x000F)
 
-#ifdef CONFIG_MCFFEC
-#      define CONFIG_OVERWRITE_ETHADDR_ONCE
-#endif                         /* FEC_ENET */
-
 #define CONFIG_EXTRA_ENV_SETTINGS              \
        "netdev=eth0\0"                         \
        "loadaddr=10000\0"                      \
index b267b74b1595f9b93d3dc63b9c37be13c39241cd..26e4ade34ee724315f99891706de774f83bdb5dc 100644 (file)
  * Network                                                             *
  *----------------------------------------------------------------------*/
 
-#ifdef CONFIG_MCFFEC
-#define CONFIG_OVERWRITE_ETHADDR_ONCE
-#endif
-
 /*-------------------------------------------------------------------------
  * Low Level Configuration Settings
  * (address mappings, register initial values, etc.)