[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1362687183-3425-1-git-send-email-alex.aring@gmail.com>
Date: Thu, 7 Mar 2013 21:13:03 +0100
From: Alexander Aring <alex.aring@...il.com>
To: davem@...emloft.net
Cc: kuznet@....inr.ac.ru, jmorris@...ei.org, yoshfuji@...ux-ipv6.org,
linux-zigbee-devel@...ts.sourceforge.net, netdev@...r.kernel.org,
Alexander Aring <alex.aring@...il.com>
Subject: [PATCH] ipv6 addrconf: Fix addrconf_ifid_eui64 of 802.15.4 devices
The function addrconf_ifid_eui64 will copy eui into dev->dev_addr.
We need first to manipulate eui[0] before we call memcpy afterwards.
Broken since commit:
5e98a36ed4bf6ea396170e3af0dd4fcbe51d772f
Since this commit I got many trouble with the ieee802154 stack.
Signed-off-by: Alexander Aring <alex.aring@...il.com>
---
net/ipv6/addrconf.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c
index fa36a67..4460237 100644
--- a/net/ipv6/addrconf.c
+++ b/net/ipv6/addrconf.c
@@ -1731,8 +1731,8 @@ static int addrconf_ifid_eui64(u8 *eui, struct net_device *dev)
{
if (dev->addr_len != IEEE802154_ADDR_LEN)
return -1;
- memcpy(eui, dev->dev_addr, 8);
eui[0] ^= 2;
+ memcpy(eui, dev->dev_addr, 8);
return 0;
}
--
1.8.1.5
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists