commit | e59ecbc345ad54e776c80a30e490c0023d2a4456 | [log] [tgz] |
---|---|---|
author | Bin Meng <bmeng.cn@gmail.com> | Wed Oct 07 21:45:42 2015 -0700 |
committer | Joe Hershberger <joe.hershberger@ni.com> | Thu Oct 29 14:05:51 2015 -0500 |
tree | 557ab362dfb12072c5066bed1802cce3e0ed6b47 | |
parent | c3944fd0310c9ee905b018feeb5dbd5262e2e9cb [diff] |
net: eth: Clear MAC address in eth_pre_remove() platdata->enetaddr was assigned to a value in dev_probe() last time. If we don't clear it, for dev_probe() at the second time, dm eth will end up treating it as a MAC address from ROM no matter where it came from originally (maybe env, ROM, or even random). Fix this by clearing platdata->enetaddr when removing an Ethernet device. Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Acked-by: Joe Hershberger <joe.hershberger@ni.com>