summaryrefslogtreecommitdiff
path: root/board/keymile
diff options
context:
space:
mode:
authorHolger Brunck <holger.brunck@keymile.com>2011-09-13 23:06:10 +0000
committerWolfgang Denk <wd@denx.de>2011-10-22 00:28:36 +0200
commit0eb0e59ed3955cd73548c8769bf594c665025dd5 (patch)
tree2c6efedab0a6348b647d5d63ed159fe429f7c0e2 /board/keymile
parent8603b69b8b04e3e34f8744b396c62833b78fd7c1 (diff)
downloadu-boot-imx-0eb0e59ed3955cd73548c8769bf594c665025dd5.zip
u-boot-imx-0eb0e59ed3955cd73548c8769bf594c665025dd5.tar.gz
u-boot-imx-0eb0e59ed3955cd73548c8769bf594c665025dd5.tar.bz2
km/common: force set ethaddr only for KM kirkwood boards
This prevents u-boot to print out "Can't overwrite "ethaddr"" each time a powerpc board starts. Signed-off-by: Holger Brunck <holger.brunck@keymile.com> cc: Wolfgang Denk <wd@denx.de>
Diffstat (limited to 'board/keymile')
-rw-r--r--board/keymile/common/ivm.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/board/keymile/common/ivm.c b/board/keymile/common/ivm.c
index bcf3aed..70d78457f 100644
--- a/board/keymile/common/ivm.c
+++ b/board/keymile/common/ivm.c
@@ -221,7 +221,12 @@ static int ivm_analyze_block2(unsigned char *buf, int len)
sprintf((char *)valbuf, "%pM", buf);
}
#endif
+#ifdef MACH_TYPE_KM_KIRKWOOD
setenv((char *)"ethaddr", (char *)valbuf);
+#else
+ if (getenv("ethaddr") == NULL)
+ setenv((char *)"ethaddr", (char *)valbuf);
+#endif
/* IVM_MacCount */
count = (buf[10] << 24) +