net: use eth_hw_addr_random() and reset addr_assign_type
authorDanny Kukawka <danny.kukawka@bisect.de>
Wed, 15 Feb 2012 06:45:40 +0000 (06:45 +0000)
committerDavid S. Miller <davem@davemloft.net>
Wed, 15 Feb 2012 20:34:17 +0000 (15:34 -0500)
commit7ce5d222190cb3ce3ae88bafde7c4fa52a5103e0
tree2b284365b7a2e11d4ba286a589bd35bc39918805
parentf2cedb63df14342ad40a8b5b324fc5d94a60b665
net: use eth_hw_addr_random() and reset addr_assign_type

Use eth_hw_addr_random() instead of calling random_ether_addr()
to set addr_assign_type correctly to NET_ADDR_RANDOM.

Reset the state to NET_ADDR_PERM as soon as the MAC get
changed via .ndo_set_mac_address.

v2: adapt to renamed eth_hw_addr_random()

Signed-off-by: Danny Kukawka <danny.kukawka@bisect.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 files changed:
drivers/net/dummy.c
drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c
drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c
drivers/net/ethernet/calxeda/xgmac.c
drivers/net/ethernet/marvell/pxa168_eth.c
drivers/net/ethernet/micrel/ks8842.c
drivers/net/ethernet/micrel/ks8851.c
drivers/net/ethernet/micrel/ks8851_mll.c
drivers/net/ethernet/microchip/enc28j60.c
drivers/net/ethernet/nvidia/forcedeth.c
drivers/net/ethernet/smsc/smsc911x.c
drivers/net/ethernet/tile/tilepro.c
drivers/net/macvlan.c
drivers/net/team/team.c
net/bridge/br_device.c
net/openvswitch/vport-internal_dev.c