diff options
author | Alexander Aring <alex.aring@gmail.com> | 2014-10-25 17:16:40 +0200 |
---|---|---|
committer | Marcel Holtmann <marcel@holtmann.org> | 2014-10-25 21:55:38 +0200 |
commit | 59d19cd70cd38afd2d9bf2e3b48c3a5bbb630b5a (patch) | |
tree | c50750db9700ada4088809468424c9e22fb59581 /net/mac802154/monitor.c | |
parent | 60741361c3ca229a1dbb18e05d11e97b7ea75d69 (diff) | |
download | linux-59d19cd70cd38afd2d9bf2e3b48c3a5bbb630b5a.tar.gz linux-59d19cd70cd38afd2d9bf2e3b48c3a5bbb630b5a.tar.bz2 linux-59d19cd70cd38afd2d9bf2e3b48c3a5bbb630b5a.zip |
mac802154: introduce IEEE802154_DEV_TO_SUB_IF
This function adds a wrapper to call netdev_priv to getting the sdata
attribute. This is similar like the IEEE80211_DEV_TO_SUB_IF function
inside wireless stack implementation.
Signed-off-by: Alexander Aring <alex.aring@gmail.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Diffstat (limited to 'net/mac802154/monitor.c')
-rw-r--r-- | net/mac802154/monitor.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/net/mac802154/monitor.c b/net/mac802154/monitor.c index 9d2ac5ea6634..f8ea6dc8dda5 100644 --- a/net/mac802154/monitor.c +++ b/net/mac802154/monitor.c @@ -36,7 +36,7 @@ static netdev_tx_t mac802154_monitor_xmit(struct sk_buff *skb, struct ieee802154_sub_if_data *sdata; u8 chan, page; - sdata = netdev_priv(dev); + sdata = IEEE802154_DEV_TO_SUB_IF(dev); /* FIXME: locking */ chan = sdata->local->phy->current_channel; @@ -105,7 +105,7 @@ void mac802154_monitor_setup(struct net_device *dev) dev->netdev_ops = &mac802154_monitor_ops; dev->ml_priv = &mac802154_mlme_reduced; - sdata = netdev_priv(dev); + sdata = IEEE802154_DEV_TO_SUB_IF(dev); sdata->type = IEEE802154_DEV_MONITOR; sdata->chan = MAC802154_CHAN_NONE; /* not initialized */ |