blackfin: replace bfin_gen_rand_mac() with eth_random_addr()

bfin_gen_rand_mac() uses __DATE__ as the seed for random ethernet
address. This makes the build non-deterministic.

In the first place, it should not be implemented as a Bfin-specific
function. Use eth_random_addr() instead.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Cc: Sonic Zhang <sonic.zhang@analog.com>
This commit is contained in:
Masahiro Yamada
2014-04-18 19:09:49 +09:00
committed by Tom Rini
parent da384a9d76
commit c42f56d96d
31 changed files with 31 additions and 69 deletions

View File

@@ -12,7 +12,6 @@
#include <netdev.h>
#include <net.h>
#include <asm/blackfin.h>
#include <asm/net.h>
DECLARE_GLOBAL_DATA_PTR;
@@ -27,7 +26,7 @@ int checkboard(void)
static void board_init_enetaddr(uchar *mac_addr)
{
puts("Warning: Generating 'random' MAC address\n");
bfin_gen_rand_mac(mac_addr);
eth_random_addr(mac_addr);
eth_setenv_enetaddr("ethaddr", mac_addr);
}