]> git.kernelconcepts.de Git - karo-tx-uboot.git/commitdiff
Allow CONFIG_REGEX to be disabled when CONFIG_NET
authorJoe Hershberger <joe.hershberger@ni.com>
Mon, 22 Jun 2015 22:57:36 +0000 (17:57 -0500)
committerLothar Waßmann <LW@KARO-electronics.de>
Tue, 8 Sep 2015 22:47:38 +0000 (00:47 +0200)
Instead of selecting REGEX when NET is enabled, make it the default, but
allow boards that are tiny to disable it and lose functionality on all
but the first Ethernet adapter.

cm-bf548, bf538f-ezkit, and bf533-stamp need this. None appear to have
more than one Ethernet interface.

Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
include/env_callback.h
lib/Kconfig
net/Kconfig

index ab5d42dd8138be17f02ac4ad304127d55d16ea22..90b95b5e6676087f00d234721c98c7e475cf4268 100644 (file)
 
 #ifdef CONFIG_REGEX
 #define ENV_DOT_ESCAPE "\\"
+#define ETHADDR_WILDCARD "\\d?"
 #else
 #define ENV_DOT_ESCAPE
+#define ETHADDR_WILDCARD
 #endif
 
 #ifdef CONFIG_CMD_DNS
@@ -53,7 +55,7 @@
        "nvlan:nvlan," \
        "vlan:vlan," \
        DNS_CALLBACK \
-       "eth\\d?addr:ethaddr,"
+       "eth" ETHADDR_WILDCARD "addr:ethaddr,"
 #else
 #define NET_CALLBACKS
 #endif
index 0cee969583d1da8638859bdcf031a860648d130e..35531080e120df94df7fe130f08e3859106f1a96 100644 (file)
@@ -41,6 +41,7 @@ config SYS_VSNPRINTF
 
 config REGEX
        bool "Enable regular expression support"
+       default y if NET
        help
          If this variable is defined, U-Boot is linked against the
          SLRE (Super Light Regular Expression) library, which adds
index 9a9846e187449c5dcda44e7c84de6b12add05640..915371df91274f51701950a0ff0543cf887d8dda 100644 (file)
@@ -4,7 +4,6 @@
 
 menuconfig NET
        bool "Networking support"
-       select REGEX
 
 if NET