aboutsummaryrefslogtreecommitdiffstats
path: root/net/mac80211/rx.c
diff options
context:
space:
mode:
authorJohannes Berg <johannes.berg@intel.com>2010-06-10 04:21:35 -0400
committerJohn W. Linville <linville@tuxdriver.com>2010-06-14 15:39:26 -0400
commitbed7ee6e44cb7633a4f9821688a6c7ae977615ed (patch)
tree0c4997408d74abbde021b11b6b1046d815524e15 /net/mac80211/rx.c
parent77a121c3a88eb00a4b5e753d083dbb7d49fefb0a (diff)
mac80211: always process blockack action from workqueue
To prepare for making the ampdu_action callback sleep, make mac80211 always process blockack action frames from the skb queue. This gets rid of the current special case for managed mode interfaces as well. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net/mac80211/rx.c')
-rw-r--r--net/mac80211/rx.c29
1 files changed, 13 insertions, 16 deletions
diff --git a/net/mac80211/rx.c b/net/mac80211/rx.c
index 40fe2798cbf5..435c2166e0c5 100644
--- a/net/mac80211/rx.c
+++ b/net/mac80211/rx.c
@@ -1950,33 +1950,29 @@ ieee80211_rx_h_action(struct ieee80211_rx_data *rx)
1950 if (len < IEEE80211_MIN_ACTION_SIZE + 1) 1950 if (len < IEEE80211_MIN_ACTION_SIZE + 1)
1951 break; 1951 break;
1952 1952
1953 if (sdata->vif.type == NL80211_IFTYPE_STATION) {
1954 skb_queue_tail(&sdata->skb_queue, rx->skb);
1955 ieee80211_queue_work(&local->hw, &sdata->work);
1956 return RX_QUEUED;
1957 }
1958
1959 switch (mgmt->u.action.u.addba_req.action_code) { 1953 switch (mgmt->u.action.u.addba_req.action_code) {
1960 case WLAN_ACTION_ADDBA_REQ: 1954 case WLAN_ACTION_ADDBA_REQ:
1961 if (len < (IEEE80211_MIN_ACTION_SIZE + 1955 if (len < (IEEE80211_MIN_ACTION_SIZE +
1962 sizeof(mgmt->u.action.u.addba_req))) 1956 sizeof(mgmt->u.action.u.addba_req)))
1963 return RX_DROP_MONITOR; 1957 goto invalid;
1964 ieee80211_process_addba_request(local, rx->sta, mgmt, len); 1958 break;
1965 goto handled;
1966 case WLAN_ACTION_ADDBA_RESP: 1959 case WLAN_ACTION_ADDBA_RESP:
1967 if (len < (IEEE80211_MIN_ACTION_SIZE + 1960 if (len < (IEEE80211_MIN_ACTION_SIZE +
1968 sizeof(mgmt->u.action.u.addba_resp))) 1961 sizeof(mgmt->u.action.u.addba_resp)))
1969 break; 1962 goto invalid;
1970 ieee80211_process_addba_resp(local, rx->sta, mgmt, len); 1963 break;
1971 goto handled;
1972 case WLAN_ACTION_DELBA: 1964 case WLAN_ACTION_DELBA:
1973 if (len < (IEEE80211_MIN_ACTION_SIZE + 1965 if (len < (IEEE80211_MIN_ACTION_SIZE +
1974 sizeof(mgmt->u.action.u.delba))) 1966 sizeof(mgmt->u.action.u.delba)))
1975 break; 1967 goto invalid;
1976 ieee80211_process_delba(sdata, rx->sta, mgmt, len); 1968 break;
1977 goto handled; 1969 default:
1970 goto invalid;
1978 } 1971 }
1979 break; 1972
1973 skb_queue_tail(&sdata->skb_queue, rx->skb);
1974 ieee80211_queue_work(&local->hw, &sdata->work);
1975 return RX_QUEUED;
1980 case WLAN_CATEGORY_SPECTRUM_MGMT: 1976 case WLAN_CATEGORY_SPECTRUM_MGMT:
1981 if (local->hw.conf.channel->band != IEEE80211_BAND_5GHZ) 1977 if (local->hw.conf.channel->band != IEEE80211_BAND_5GHZ)
1982 break; 1978 break;
@@ -2033,6 +2029,7 @@ ieee80211_rx_h_action(struct ieee80211_rx_data *rx)
2033 return RX_QUEUED; 2029 return RX_QUEUED;
2034 } 2030 }
2035 2031
2032 invalid:
2036 /* 2033 /*
2037 * For AP mode, hostapd is responsible for handling any action 2034 * For AP mode, hostapd is responsible for handling any action
2038 * frames that we didn't handle, including returning unknown 2035 * frames that we didn't handle, including returning unknown