From: Marek Vasut Date: Sat, 12 Nov 2016 15:28:40 +0000 (+0100) Subject: net: write enetaddr down to hardware on env_callback X-Git-Tag: v2016.11~3 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=73d570a76ddee0a18445cd53c9473a445d2f08a4;p=u-boot net: write enetaddr down to hardware on env_callback If mac-address is changed using "setenv ethaddr ...." command the new mac-adress also must be written into the responsible ethernet driver. This fixes the legacy ethernet handling. Signed-off-by: Marek Vasut Cc: Hannes Schmelzer Cc: Joe Hershberger Cc: Tom Rini Reviewed-by: Hannes Schmelzer --- diff --git a/net/eth_legacy.c b/net/eth_legacy.c index d6d7ceeafd..1354f49ec0 100644 --- a/net/eth_legacy.c +++ b/net/eth_legacy.c @@ -118,6 +118,7 @@ static int on_ethaddr(const char *name, const char *value, enum env_op op, case env_op_create: case env_op_overwrite: eth_parse_enetaddr(value, dev->enetaddr); + eth_write_hwaddr(dev, "eth", dev->index); break; case env_op_delete: memset(dev->enetaddr, 0, 6);