diff options
author | Alexander Aring <aar@pengutronix.de> | 2016-04-11 05:04:15 -0400 |
---|---|---|
committer | Marcel Holtmann <marcel@holtmann.org> | 2016-04-13 04:41:08 -0400 |
commit | 118a5cf8ae236cdfa1eb4f21530843a8494722ef (patch) | |
tree | f7d743055aa6fb4e20ae88eaff4b372009a9e081 /include/net/mac802154.h | |
parent | b7594148c73cb506487b5f00a6574beceea0e3a0 (diff) |
ieee802154: add short address helpers
This patch introduce some short address handling functionality into
ieee802154 headers.
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>
Diffstat (limited to 'include/net/mac802154.h')
-rw-r--r-- | include/net/mac802154.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/include/net/mac802154.h b/include/net/mac802154.h index 6cd7a70706a9..e465c8551ac3 100644 --- a/include/net/mac802154.h +++ b/include/net/mac802154.h | |||
@@ -288,6 +288,16 @@ static inline void ieee802154_le16_to_be16(void *be16_dst, const void *le16_src) | |||
288 | } | 288 | } |
289 | 289 | ||
290 | /** | 290 | /** |
291 | * ieee802154_be16_to_le16 - copies and convert be16 to le16 | ||
292 | * @le16_dst: le16 destination pointer | ||
293 | * @be16_src: be16 source pointer | ||
294 | */ | ||
295 | static inline void ieee802154_be16_to_le16(void *le16_dst, const void *be16_src) | ||
296 | { | ||
297 | put_unaligned_le16(get_unaligned_be16(be16_src), le16_dst); | ||
298 | } | ||
299 | |||
300 | /** | ||
291 | * ieee802154_alloc_hw - Allocate a new hardware device | 301 | * ieee802154_alloc_hw - Allocate a new hardware device |
292 | * | 302 | * |
293 | * This must be called once for each hardware device. The returned pointer | 303 | * This must be called once for each hardware device. The returned pointer |