diff options
author | Johannes Berg <johannes@sipsolutions.net> | 2010-02-19 13:06:56 -0500 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2010-02-19 15:52:52 -0500 |
commit | 4ca778605cfec53d8a689f0b57babb93b030c784 (patch) | |
tree | b24400814c58fa5bfad5de884cea334e95b338b0 /drivers/net/wireless | |
parent | 1d669cbf52a01490c14a999daa978e0fa00b494d (diff) |
ath9k: convert to new station add/remove callbacks
This converts ath9k to use the new station
add/remove callbacks instead of using the
old sta_notify callback.
Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless')
-rw-r--r-- | drivers/net/wireless/ath/ath9k/main.c | 35 |
1 files changed, 20 insertions, 15 deletions
diff --git a/drivers/net/wireless/ath/ath9k/main.c b/drivers/net/wireless/ath/ath9k/main.c index 9c8f925c2093..67ca4e5a6017 100644 --- a/drivers/net/wireless/ath/ath9k/main.c +++ b/drivers/net/wireless/ath/ath9k/main.c | |||
@@ -1684,24 +1684,28 @@ static void ath9k_configure_filter(struct ieee80211_hw *hw, | |||
1684 | "Set HW RX filter: 0x%x\n", rfilt); | 1684 | "Set HW RX filter: 0x%x\n", rfilt); |
1685 | } | 1685 | } |
1686 | 1686 | ||
1687 | static void ath9k_sta_notify(struct ieee80211_hw *hw, | 1687 | static int ath9k_sta_add(struct ieee80211_hw *hw, |
1688 | struct ieee80211_vif *vif, | 1688 | struct ieee80211_vif *vif, |
1689 | enum sta_notify_cmd cmd, | 1689 | struct ieee80211_sta *sta) |
1690 | struct ieee80211_sta *sta) | ||
1691 | { | 1690 | { |
1692 | struct ath_wiphy *aphy = hw->priv; | 1691 | struct ath_wiphy *aphy = hw->priv; |
1693 | struct ath_softc *sc = aphy->sc; | 1692 | struct ath_softc *sc = aphy->sc; |
1694 | 1693 | ||
1695 | switch (cmd) { | 1694 | ath_node_attach(sc, sta); |
1696 | case STA_NOTIFY_ADD: | 1695 | |
1697 | ath_node_attach(sc, sta); | 1696 | return 0; |
1698 | break; | 1697 | } |
1699 | case STA_NOTIFY_REMOVE: | 1698 | |
1700 | ath_node_detach(sc, sta); | 1699 | static int ath9k_sta_remove(struct ieee80211_hw *hw, |
1701 | break; | 1700 | struct ieee80211_vif *vif, |
1702 | default: | 1701 | struct ieee80211_sta *sta) |
1703 | break; | 1702 | { |
1704 | } | 1703 | struct ath_wiphy *aphy = hw->priv; |
1704 | struct ath_softc *sc = aphy->sc; | ||
1705 | |||
1706 | ath_node_detach(sc, sta); | ||
1707 | |||
1708 | return 0; | ||
1705 | } | 1709 | } |
1706 | 1710 | ||
1707 | static int ath9k_conf_tx(struct ieee80211_hw *hw, u16 queue, | 1711 | static int ath9k_conf_tx(struct ieee80211_hw *hw, u16 queue, |
@@ -2045,7 +2049,8 @@ struct ieee80211_ops ath9k_ops = { | |||
2045 | .remove_interface = ath9k_remove_interface, | 2049 | .remove_interface = ath9k_remove_interface, |
2046 | .config = ath9k_config, | 2050 | .config = ath9k_config, |
2047 | .configure_filter = ath9k_configure_filter, | 2051 | .configure_filter = ath9k_configure_filter, |
2048 | .sta_notify = ath9k_sta_notify, | 2052 | .sta_add = ath9k_sta_add, |
2053 | .sta_remove = ath9k_sta_remove, | ||
2049 | .conf_tx = ath9k_conf_tx, | 2054 | .conf_tx = ath9k_conf_tx, |
2050 | .bss_info_changed = ath9k_bss_info_changed, | 2055 | .bss_info_changed = ath9k_bss_info_changed, |
2051 | .set_key = ath9k_set_key, | 2056 | .set_key = ath9k_set_key, |