diff options
author | Krzysztof Halasa <khc@pm.waw.pl> | 2008-02-02 00:39:50 +0300 |
---|---|---|
committer | Jeff Garzik <jeff@garzik.org> | 2008-02-05 21:31:40 +0300 |
commit | 47eaa267a5db1729d238f977364e297b8963e115 (patch) | |
tree | d0185dcffbbb272ac422a00a9c0e44cf7850438b /drivers/net/wan/hdlc_raw_eth.c | |
parent | 40d25142f2ef27084fc317ac8bb5bae460c8ea72 (diff) | |
download | linux-47eaa267a5db1729d238f977364e297b8963e115.tar.xz |
Generic HDLC - use random_ether_addr()
Generic HDLC now uses random_ether_addr() for generating MAC addresse
for Ethernet-alike interfaces.
Signed-off-by: Krzysztof Halasa <khc@pm.waw.pl>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'drivers/net/wan/hdlc_raw_eth.c')
-rw-r--r-- | drivers/net/wan/hdlc_raw_eth.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/net/wan/hdlc_raw_eth.c b/drivers/net/wan/hdlc_raw_eth.c index 11b16bdfe6aa..d20c685f6711 100644 --- a/drivers/net/wan/hdlc_raw_eth.c +++ b/drivers/net/wan/hdlc_raw_eth.c @@ -18,7 +18,6 @@ #include <linux/init.h> #include <linux/skbuff.h> #include <linux/pkt_sched.h> -#include <linux/random.h> #include <linux/inetdevice.h> #include <linux/lapb.h> #include <linux/rtnetlink.h> @@ -107,8 +106,7 @@ static int raw_eth_ioctl(struct net_device *dev, struct ifreq *ifr) ether_setup(dev); dev->change_mtu = old_ch_mtu; dev->tx_queue_len = old_qlen; - memcpy(dev->dev_addr, "\x00\x01", 2); - get_random_bytes(dev->dev_addr + 2, ETH_ALEN - 2); + random_ether_addr(dev->dev_addr); netif_dormant_off(dev); return 0; } |