summaryrefslogtreecommitdiffstats
path: root/net/mac802154/main.c
diff options
context:
space:
mode:
authorAlexander Aring <alex.aring@gmail.com>2014-10-25 17:16:34 +0200
committerMarcel Holtmann <marcel@holtmann.org>2014-10-25 21:55:37 +0200
commit5a50439775853a8d565115edb63a5ab4bb780479 (patch)
tree8c2186840f6c46198a46234dede46a5e990f93fa /net/mac802154/main.c
parent36426484fcaca2153616d6f3496b389a5b11bd9f (diff)
downloadlinux-5a50439775853a8d565115edb63a5ab4bb780479.tar.bz2
ieee802154: rename ieee802154_dev to ieee802154_hw
The identical struct of the wireless stack implementation is named ieee80211_hw. This is useful to name the variable hw instead of get confusing with netdev dev variable. Signed-off-by: Alexander Aring <alex.aring@gmail.com> Cc: Alan Ott <alan@signal11.us> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Diffstat (limited to 'net/mac802154/main.c')
-rw-r--r--net/mac802154/main.c34
1 files changed, 17 insertions, 17 deletions
diff --git a/net/mac802154/main.c b/net/mac802154/main.c
index 9798c741739c..b0bcc063e9af 100644
--- a/net/mac802154/main.c
+++ b/net/mac802154/main.c
@@ -235,8 +235,8 @@ static int mac802154_set_frame_retries(struct wpan_phy *phy, s8 retries)
return priv->ops->set_frame_retries(&priv->hw, retries);
}
-struct ieee802154_dev *
-ieee802154_alloc_device(size_t priv_data_len, struct ieee802154_ops *ops)
+struct ieee802154_hw *
+ieee802154_alloc_hw(size_t priv_data_len, struct ieee802154_ops *ops)
{
struct wpan_phy *phy;
struct mac802154_priv *priv;
@@ -285,9 +285,9 @@ ieee802154_alloc_device(size_t priv_data_len, struct ieee802154_ops *ops)
return &priv->hw;
}
-EXPORT_SYMBOL(ieee802154_alloc_device);
+EXPORT_SYMBOL(ieee802154_alloc_hw);
-void ieee802154_free_device(struct ieee802154_dev *hw)
+void ieee802154_free_hw(struct ieee802154_hw *hw)
{
struct mac802154_priv *priv = mac802154_to_priv(hw);
@@ -297,49 +297,49 @@ void ieee802154_free_device(struct ieee802154_dev *hw)
wpan_phy_free(priv->phy);
}
-EXPORT_SYMBOL(ieee802154_free_device);
+EXPORT_SYMBOL(ieee802154_free_hw);
-int ieee802154_register_device(struct ieee802154_dev *dev)
+int ieee802154_register_hw(struct ieee802154_hw *hw)
{
- struct mac802154_priv *priv = mac802154_to_priv(dev);
+ struct mac802154_priv *priv = mac802154_to_priv(hw);
int rc = -ENOSYS;
- if (dev->flags & IEEE802154_HW_TXPOWER) {
+ if (hw->flags & IEEE802154_HW_TXPOWER) {
if (!priv->ops->set_txpower)
goto out;
priv->phy->set_txpower = mac802154_set_txpower;
}
- if (dev->flags & IEEE802154_HW_LBT) {
+ if (hw->flags & IEEE802154_HW_LBT) {
if (!priv->ops->set_lbt)
goto out;
priv->phy->set_lbt = mac802154_set_lbt;
}
- if (dev->flags & IEEE802154_HW_CCA_MODE) {
+ if (hw->flags & IEEE802154_HW_CCA_MODE) {
if (!priv->ops->set_cca_mode)
goto out;
priv->phy->set_cca_mode = mac802154_set_cca_mode;
}
- if (dev->flags & IEEE802154_HW_CCA_ED_LEVEL) {
+ if (hw->flags & IEEE802154_HW_CCA_ED_LEVEL) {
if (!priv->ops->set_cca_ed_level)
goto out;
priv->phy->set_cca_ed_level = mac802154_set_cca_ed_level;
}
- if (dev->flags & IEEE802154_HW_CSMA_PARAMS) {
+ if (hw->flags & IEEE802154_HW_CSMA_PARAMS) {
if (!priv->ops->set_csma_params)
goto out;
priv->phy->set_csma_params = mac802154_set_csma_params;
}
- if (dev->flags & IEEE802154_HW_FRAME_RETRIES) {
+ if (hw->flags & IEEE802154_HW_FRAME_RETRIES) {
if (!priv->ops->set_frame_retries)
goto out;
@@ -377,11 +377,11 @@ out_wq:
out:
return rc;
}
-EXPORT_SYMBOL(ieee802154_register_device);
+EXPORT_SYMBOL(ieee802154_register_hw);
-void ieee802154_unregister_device(struct ieee802154_dev *dev)
+void ieee802154_unregister_hw(struct ieee802154_hw *hw)
{
- struct mac802154_priv *priv = mac802154_to_priv(dev);
+ struct mac802154_priv *priv = mac802154_to_priv(hw);
struct mac802154_sub_if_data *sdata, *next;
flush_workqueue(priv->dev_workqueue);
@@ -405,7 +405,7 @@ void ieee802154_unregister_device(struct ieee802154_dev *dev)
wpan_phy_unregister(priv->phy);
}
-EXPORT_SYMBOL(ieee802154_unregister_device);
+EXPORT_SYMBOL(ieee802154_unregister_hw);
MODULE_DESCRIPTION("IEEE 802.15.4 implementation");
MODULE_LICENSE("GPL v2");