diff options
author | Matthias Fuchs <matthias.fuchs@esd-electronics.com> | 2008-01-17 07:45:05 +0100 |
---|---|---|
committer | Ben Warren <biggerbadderben@gmail.com> | 2008-01-17 09:41:09 -0500 |
commit | e16925773211291b562e77187061e9dd1d757217 (patch) | |
tree | 870b7b268b49b5f223a95a85ee31b1c29fdd848f /net | |
parent | 7f52fa3c2df59e49dc2badd7c084cf2d007c438f (diff) |
net: add 'ethrotate' environment variable
[PATCH] net: add 'ethrotate' environment variable
This patch replaces the buildtime configuration option
CONFIG_NET_DO_NOT_TRY_ANOTHER through the 'ethrotate' runtime
configuration veriable. See README.
Signed-off-by: Matthias Fuchs <matthias.fuchs@esd-electronics.com>
Signed-off-by: Ben Warren <biggerbadderben@gmail.com>
Diffstat (limited to 'net')
-rw-r--r-- | net/eth.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/net/eth.c b/net/eth.c index 63a4cb652a2..316e8177862 100644 --- a/net/eth.c +++ b/net/eth.c @@ -525,6 +525,15 @@ int eth_receive(volatile void *packet, int length) void eth_try_another(int first_restart) { static struct eth_device *first_failed = NULL; + char *ethrotate; + + /* + * Do not rotate between network interfaces when + * 'ethrotate' variable is set to 'no'. + */ + if (((ethrotate = getenv ("ethrotate")) != NULL) && + (strcmp(ethrotate, "no") == 0)) + return; if (!eth_current) return; |