The following commit has been merged in the master branch: commit 957c36fbdb1d37b4d7b6b2faccb1ce3f34fc50ce Author: simon simon@45894c77-fb22-0410-b583-ff6e7d5dbf6c Date: Sat Oct 17 16:28:30 2009 +0000
use random ethernet address generator from the kernel
git-svn-id: http://downloads.open-mesh.net/svn/batman/trunk/batman-adv-kernelland@1446 45894c77-fb22-0410-b583-ff6e7d5dbf6c
diff --git a/soft-interface.c b/soft-interface.c index d916764..08a16e3 100644 --- a/soft-interface.c +++ b/soft-interface.c @@ -119,8 +119,7 @@ void interface_setup(struct net_device *dev) * 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);