Author: simon Date: 2009-10-17 16:28:30 +0000 (Sat, 17 Oct 2009) New Revision: 1446
Modified: trunk/batman-adv-kernelland/soft-interface.c Log: use random ethernet address generator from the kernel
Modified: trunk/batman-adv-kernelland/soft-interface.c =================================================================== --- trunk/batman-adv-kernelland/soft-interface.c 2009-10-16 23:35:21 UTC (rev 1445) +++ trunk/batman-adv-kernelland/soft-interface.c 2009-10-17 16:28:30 UTC (rev 1446) @@ -119,8 +119,7 @@ * skbuff for our header */
/* generate random address */ - *(u16 *)dev_addr = __constant_htons(0x00FF); - get_random_bytes(dev_addr + sizeof(u16), 4); + random_ether_addr(dev_addr); memcpy(dev->dev_addr, dev_addr, sizeof(dev->dev_addr));
SET_ETHTOOL_OPS(dev, &bat_ethtool_ops);