aboutsummaryrefslogtreecommitdiffstats
path: root/net/ieee802154/core.c
diff options
context:
space:
mode:
authorAlexander Aring <alex.aring@gmail.com>2015-09-28 09:00:25 +0200
committerMarcel Holtmann <marcel@holtmann.org>2015-09-30 13:16:44 +0200
commita26c5fd7622d4951425131d54a8c99f076fe2068 (patch)
tree1a2a5c0db1ee837902382a48f655a61840a8cc73 /net/ieee802154/core.c
parentnl802154: use nla_get_le64 for get extended addr (diff)
downloadlinux-dev-a26c5fd7622d4951425131d54a8c99f076fe2068.tar.xz
linux-dev-a26c5fd7622d4951425131d54a8c99f076fe2068.zip
nl802154: add support for security layer
This patch adds support for accessing mac802154 llsec implementation over nl802154. I added for a new Kconfig entry to provide this functionality CONFIG_IEEE802154_NL802154_EXPERIMENTAL. This interface is still in development. It provides to change security parameters and add/del/dump entries of security tables. Later we can add also a get to get an entry by unique identifier. Cc: Phoebe Buckheister <phoebe.buckheister@itwm.fraunhofer.de> Signed-off-by: Alexander Aring <alex.aring@gmail.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Diffstat (limited to 'net/ieee802154/core.c')
-rw-r--r--net/ieee802154/core.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/net/ieee802154/core.c b/net/ieee802154/core.c
index b0248e934230..c35fdfa6d04e 100644
--- a/net/ieee802154/core.c
+++ b/net/ieee802154/core.c
@@ -95,6 +95,18 @@ cfg802154_rdev_by_wpan_phy_idx(int wpan_phy_idx)
return result;
}
+struct wpan_phy *wpan_phy_idx_to_wpan_phy(int wpan_phy_idx)
+{
+ struct cfg802154_registered_device *rdev;
+
+ ASSERT_RTNL();
+
+ rdev = cfg802154_rdev_by_wpan_phy_idx(wpan_phy_idx);
+ if (!rdev)
+ return NULL;
+ return &rdev->wpan_phy;
+}
+
struct wpan_phy *
wpan_phy_new(const struct cfg802154_ops *ops, size_t priv_size)
{