summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>2013-03-09 09:11:57 (GMT)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2013-03-20 20:10:59 (GMT)
commit363e95a8de7250190a38ef871923b5e0e27f1ab4 (patch)
treecd42395b4db763b5351f7eb94ad26240efe20f9e
parent451b3450126c02c195c6db7862fe0b39fa6e3fc2 (diff)
downloadlinux-fsl-qoriq-363e95a8de7250190a38ef871923b5e0e27f1ab4.tar.xz
6lowpan: Fix endianness issue in is_addr_link_local().
[ Upstream commit 9026c4927254f5bea695cc3ef2e255280e6a3011 ] Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--net/ieee802154/6lowpan.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/ieee802154/6lowpan.h b/net/ieee802154/6lowpan.h
index 8c2251f..bba5f83 100644
--- a/net/ieee802154/6lowpan.h
+++ b/net/ieee802154/6lowpan.h
@@ -84,7 +84,7 @@
(memcmp(addr1, addr2, length >> 3) == 0)
/* local link, i.e. FE80::/10 */
-#define is_addr_link_local(a) (((a)->s6_addr16[0]) == 0x80FE)
+#define is_addr_link_local(a) (((a)->s6_addr16[0]) == htons(0xFE80))
/*
* check whether we can compress the IID to 16 bits,