summaryrefslogtreecommitdiffstats
path: root/net/mac802154/cfg.c
diff options
context:
space:
mode:
authorAlexander Aring <alex.aring@gmail.com>2015-06-21 16:45:20 +0200
committerMarcel Holtmann <marcel@holtmann.org>2015-07-23 17:10:48 +0200
commitd77b4852b4d3698a90eef219acf9cddc964b1f3a (patch)
treee6f399f7f906a271dbfeb0533280ab78da8ee36c /net/mac802154/cfg.c
parentBluetooth: dtl1_cs: Fix coding style -- clean up (diff)
downloadlinux-d77b4852b4d3698a90eef219acf9cddc964b1f3a.tar.xz
linux-d77b4852b4d3698a90eef219acf9cddc964b1f3a.zip
mac802154: add llsec address update workaround
This patch adds a workaround for using the new nl802154 netlink interface with the old ieee802154 netlink interface togehter. The nl802154 currently supports no access for llsec layer, currently there are users outside which are using both interfaces at the same time. This patch adds a necessary call when addresses are updated. Reported-by: Simon Vincent <simon.vincent@xsilon.com> Suggested-by: 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/mac802154/cfg.c')
-rw-r--r--net/mac802154/cfg.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/net/mac802154/cfg.c b/net/mac802154/cfg.c
index 317c4662e544..44db8613812e 100644
--- a/net/mac802154/cfg.c
+++ b/net/mac802154/cfg.c
@@ -145,13 +145,18 @@ static int
ieee802154_set_pan_id(struct wpan_phy *wpan_phy, struct wpan_dev *wpan_dev,
__le16 pan_id)
{
+ int ret;
+
ASSERT_RTNL();
if (wpan_dev->pan_id == pan_id)
return 0;
- wpan_dev->pan_id = pan_id;
- return 0;
+ ret = mac802154_wpan_update_llsec(wpan_dev->netdev);
+ if (!ret)
+ wpan_dev->pan_id = pan_id;
+
+ return ret;
}
static int