From: Mike Frysinger Date: Thu, 10 Jun 2010 02:10:48 +0000 (-0400) Subject: net: warn about spaces in device names X-Git-Tag: v2010.09-rc1~82^2~2^2~14 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=1384f3bb8a4f9066805b70c1418eda78ecb73fdd;p=u-boot 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 Signed-off-by: Ben Warren --- diff --git a/net/eth.c b/net/eth.c index 83d559c120..de6d5c6040 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)) {