mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-11-24 14:51:00 +07:00
ieee802154: 6lowpan: fix short addr hash
The short address is unique in combination with the panid. This patch will add the panid for generating an ieee802154 address hash. Reviewed-by: Stefan Schmidt <stefan@osg.samsung.com> Signed-off-by: Alexander Aring <aar@pengutronix.de> Acked-by: Jukka Rissanen <jukka.rissanen@linux.intel.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
This commit is contained in:
parent
9e3b71f343
commit
5a7f97e570
@ -41,7 +41,7 @@ static inline u32 ieee802154_addr_hash(const struct ieee802154_addr *a)
|
||||
return (((__force u64)a->extended_addr) >> 32) ^
|
||||
(((__force u64)a->extended_addr) & 0xffffffff);
|
||||
case IEEE802154_ADDR_SHORT:
|
||||
return (__force u32)(a->short_addr);
|
||||
return (__force u32)(a->short_addr + (a->pan_id << 16));
|
||||
default:
|
||||
return 0;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user