summaryrefslogtreecommitdiffstats
path: root/net/mac802154/mib.c
diff options
context:
space:
mode:
authorAlexander Aring <alex.aring@gmail.com>2014-11-09 08:36:45 +0100
committerMarcel Holtmann <marcel@holtmann.org>2014-11-09 19:50:27 +0100
commit863e88f255dac0657e57d5f1a1f95ee8733f8c13 (patch)
treed1b5c0e373969cdd11c55e1fce9ba398cb05ae54 /net/mac802154/mib.c
parentb0c42cd7b210efc74aa4bfc3e39a2814dfaa9b89 (diff)
downloadlinux-stable-863e88f255dac0657e57d5f1a1f95ee8733f8c13.tar.gz
linux-stable-863e88f255dac0657e57d5f1a1f95ee8733f8c13.tar.bz2
linux-stable-863e88f255dac0657e57d5f1a1f95ee8733f8c13.zip
mac802154: move mac pib attributes into wpan_dev
This patch moves all mac pib attributes into the wpan_dev struct. Furthermore we can easier access these attributes over the netdev 802154_ptr pointer. Currently this is only possible over a complicated callback structure in mac802154 because subif data structure is accessable inside mac802154 only. Signed-off-by: Alexander Aring <alex.aring@gmail.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Diffstat (limited to 'net/mac802154/mib.c')
-rw-r--r--net/mac802154/mib.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/net/mac802154/mib.c b/net/mac802154/mib.c
index 6fa749154baf..3596b29ead6b 100644
--- a/net/mac802154/mib.c
+++ b/net/mac802154/mib.c
@@ -33,7 +33,7 @@ void mac802154_dev_set_short_addr(struct net_device *dev, __le16 val)
BUG_ON(dev->type != ARPHRD_IEEE802154);
spin_lock_bh(&sdata->mib_lock);
- sdata->short_addr = val;
+ sdata->wpan_dev.short_addr = val;
spin_unlock_bh(&sdata->mib_lock);
}
@@ -45,7 +45,7 @@ __le16 mac802154_dev_get_short_addr(const struct net_device *dev)
BUG_ON(dev->type != ARPHRD_IEEE802154);
spin_lock_bh(&sdata->mib_lock);
- ret = sdata->short_addr;
+ ret = sdata->wpan_dev.short_addr;
spin_unlock_bh(&sdata->mib_lock);
return ret;
@@ -59,7 +59,7 @@ __le16 mac802154_dev_get_pan_id(const struct net_device *dev)
BUG_ON(dev->type != ARPHRD_IEEE802154);
spin_lock_bh(&sdata->mib_lock);
- ret = sdata->pan_id;
+ ret = sdata->wpan_dev.pan_id;
spin_unlock_bh(&sdata->mib_lock);
return ret;
@@ -72,7 +72,7 @@ void mac802154_dev_set_pan_id(struct net_device *dev, __le16 val)
BUG_ON(dev->type != ARPHRD_IEEE802154);
spin_lock_bh(&sdata->mib_lock);
- sdata->pan_id = val;
+ sdata->wpan_dev.pan_id = val;
spin_unlock_bh(&sdata->mib_lock);
}
@@ -82,7 +82,7 @@ u8 mac802154_dev_get_dsn(const struct net_device *dev)
BUG_ON(dev->type != ARPHRD_IEEE802154);
- return sdata->dsn++;
+ return sdata->wpan_dev.dsn++;
}
void mac802154_dev_set_page_channel(struct net_device *dev, u8 page, u8 chan)