aboutsummaryrefslogtreecommitdiff
path: root/net
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2010-06-09 22:10:48 -0400
committerBen Warren <biggerbadderben@gmail.com>2010-07-12 00:14:28 -0700
commit1384f3bb8a4f9066805b70c1418eda78ecb73fdd (patch)
tree86d0d7a993c009da070dc562e620a03d86679281 /net
parentf9abdfe0f27cccd67b4d7dd3e998e2a7a61119d7 (diff)
downloadu-boot-1384f3bb8a4f9066805b70c1418eda78ecb73fdd.zip
u-boot-1384f3bb8a4f9066805b70c1418eda78ecb73fdd.tar.gz
u-boot-1384f3bb8a4f9066805b70c1418eda78ecb73fdd.tar.bz2
net: warn about spaces in device names
Some commands operate on eth device names (like 'mii'), but those cannot be passed on the command line as one argument. So detect devices like these and warn about them so someone will fix it. Signed-off-by: Mike Frysinger <vapier@gentoo.org> Signed-off-by: Ben Warren <biggerbadderben@gmail.com>
Diffstat (limited to 'net')
-rw-r--r--net/eth.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/net/eth.c b/net/eth.c
index 83d559c..de6d5c6 100644
--- a/net/eth.c
+++ b/net/eth.c
@@ -234,6 +234,9 @@ int eth_initialize(bd_t *bis)
puts (" [PRIME]");
}
+ if (strchr(dev->name, ' '))
+ puts("\nWarning: eth device name has a space!\n");
+
eth_getenv_enetaddr_by_index(eth_number, env_enetaddr);
if (memcmp(env_enetaddr, "\0\0\0\0\0\0", 6)) {