Commit 66b0470a authored by Johannes Berg's avatar Johannes Berg Committed by John W. Linville

mac80211: remove ieee80211_sta_stop_rx_ba_session

All callers of ieee80211_sta_stop_rx_ba_session can
just call __ieee80211_stop_rx_ba_session instead
because they already have the station struct, so do
that and remove ieee80211_sta_stop_rx_ba_session.
Signed-off-by: default avatarJohannes Berg <johannes@sipsolutions.net>
Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
parent 2b43ae6d
...@@ -79,28 +79,9 @@ void __ieee80211_stop_rx_ba_session(struct sta_info *sta, u16 tid, ...@@ -79,28 +79,9 @@ void __ieee80211_stop_rx_ba_session(struct sta_info *sta, u16 tid,
spin_unlock_bh(&sta->lock); spin_unlock_bh(&sta->lock);
} }
void ieee80211_sta_stop_rx_ba_session(struct ieee80211_sub_if_data *sdata, u8 *ra, u16 tid,
u16 initiator, u16 reason)
{
struct sta_info *sta;
rcu_read_lock();
sta = sta_info_get(sdata, ra);
if (!sta) {
rcu_read_unlock();
return;
}
__ieee80211_stop_rx_ba_session(sta, tid, initiator, reason);
rcu_read_unlock();
}
/* /*
* After accepting the AddBA Request we activated a timer, * After accepting the AddBA Request we activated a timer,
* resetting it after each frame that arrives from the originator. * resetting it after each frame that arrives from the originator.
* if this timer expires ieee80211_sta_stop_rx_ba_session will be executed.
*/ */
static void sta_rx_agg_session_timer_expired(unsigned long data) static void sta_rx_agg_session_timer_expired(unsigned long data)
{ {
...@@ -116,9 +97,8 @@ static void sta_rx_agg_session_timer_expired(unsigned long data) ...@@ -116,9 +97,8 @@ static void sta_rx_agg_session_timer_expired(unsigned long data)
#ifdef CONFIG_MAC80211_HT_DEBUG #ifdef CONFIG_MAC80211_HT_DEBUG
printk(KERN_DEBUG "rx session timer expired on tid %d\n", (u16)*ptid); printk(KERN_DEBUG "rx session timer expired on tid %d\n", (u16)*ptid);
#endif #endif
ieee80211_sta_stop_rx_ba_session(sta->sdata, sta->sta.addr, __ieee80211_stop_rx_ba_session(sta, *ptid, WLAN_BACK_RECIPIENT,
(u16)*ptid, WLAN_BACK_TIMER, WLAN_REASON_QSTA_TIMEOUT);
WLAN_REASON_QSTA_TIMEOUT);
} }
static void ieee80211_send_addba_resp(struct ieee80211_sub_if_data *sdata, u8 *da, u16 tid, static void ieee80211_send_addba_resp(struct ieee80211_sub_if_data *sdata, u8 *da, u16 tid,
......
...@@ -175,8 +175,7 @@ void ieee80211_process_delba(struct ieee80211_sub_if_data *sdata, ...@@ -175,8 +175,7 @@ void ieee80211_process_delba(struct ieee80211_sub_if_data *sdata,
#endif /* CONFIG_MAC80211_HT_DEBUG */ #endif /* CONFIG_MAC80211_HT_DEBUG */
if (initiator == WLAN_BACK_INITIATOR) if (initiator == WLAN_BACK_INITIATOR)
ieee80211_sta_stop_rx_ba_session(sdata, sta->sta.addr, tid, __ieee80211_stop_rx_ba_session(sta, tid, WLAN_BACK_INITIATOR, 0);
WLAN_BACK_INITIATOR, 0);
else { /* WLAN_BACK_RECIPIENT */ else { /* WLAN_BACK_RECIPIENT */
spin_lock_bh(&sta->lock); spin_lock_bh(&sta->lock);
if (sta->ampdu_mlme.tid_state_tx[tid] & HT_ADDBA_REQUESTED_MSK) if (sta->ampdu_mlme.tid_state_tx[tid] & HT_ADDBA_REQUESTED_MSK)
......
...@@ -1098,8 +1098,6 @@ int ieee80211_send_smps_action(struct ieee80211_sub_if_data *sdata, ...@@ -1098,8 +1098,6 @@ int ieee80211_send_smps_action(struct ieee80211_sub_if_data *sdata,
enum ieee80211_smps_mode smps, const u8 *da, enum ieee80211_smps_mode smps, const u8 *da,
const u8 *bssid); const u8 *bssid);
void ieee80211_sta_stop_rx_ba_session(struct ieee80211_sub_if_data *sdata, u8 *da,
u16 tid, u16 initiator, u16 reason);
void __ieee80211_stop_rx_ba_session(struct sta_info *sta, u16 tid, void __ieee80211_stop_rx_ba_session(struct sta_info *sta, u16 tid,
u16 initiator, u16 reason); u16 initiator, u16 reason);
void ieee80211_sta_tear_down_BA_sessions(struct sta_info *sta); void ieee80211_sta_tear_down_BA_sessions(struct sta_info *sta);
......
...@@ -739,8 +739,8 @@ static void ieee80211_rx_reorder_ampdu(struct ieee80211_rx_data *rx, ...@@ -739,8 +739,8 @@ static void ieee80211_rx_reorder_ampdu(struct ieee80211_rx_data *rx,
/* if this mpdu is fragmented - terminate rx aggregation session */ /* if this mpdu is fragmented - terminate rx aggregation session */
sc = le16_to_cpu(hdr->seq_ctrl); sc = le16_to_cpu(hdr->seq_ctrl);
if (sc & IEEE80211_SCTL_FRAG) { if (sc & IEEE80211_SCTL_FRAG) {
ieee80211_sta_stop_rx_ba_session(sta->sdata, sta->sta.addr, __ieee80211_stop_rx_ba_session(sta, tid, WLAN_BACK_RECIPIENT,
tid, 0, WLAN_REASON_QSTA_REQUIRE_SETUP); WLAN_REASON_QSTA_REQUIRE_SETUP);
dev_kfree_skb(skb); dev_kfree_skb(skb);
return; return;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment