aboutsummaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
authorJohannes Berg <johannes.berg@intel.com>2012-03-09 06:49:21 -0500
committerJohn W. Linville <linville@tuxdriver.com>2012-03-12 14:19:38 -0400
commit177958e9679c23537411066cc41b205635dacb14 (patch)
tree9c5b4cebbe1cf1ba17a45b9aa660cde82619a958 /net
parent3789d59c24cb142e4590492c3b5137a7c3dec352 (diff)
mac80211: remove tx_sync
When the station state callback was added, this was no longer needed in theory. With the iwlwifi changes to remove use of it landing, we can kill the entire tx-sync framework again, RIP. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net')
-rw-r--r--net/mac80211/driver-ops.h35
-rw-r--r--net/mac80211/driver-trace.h43
-rw-r--r--net/mac80211/ieee80211_i.h1
-rw-r--r--net/mac80211/mlme.c41
4 files changed, 0 insertions, 120 deletions
diff --git a/net/mac80211/driver-ops.h b/net/mac80211/driver-ops.h
index 70dfb6415c20..af4691fed645 100644
--- a/net/mac80211/driver-ops.h
+++ b/net/mac80211/driver-ops.h
@@ -168,41 +168,6 @@ static inline void drv_bss_info_changed(struct ieee80211_local *local,
168 trace_drv_return_void(local); 168 trace_drv_return_void(local);
169} 169}
170 170
171static inline int drv_tx_sync(struct ieee80211_local *local,
172 struct ieee80211_sub_if_data *sdata,
173 const u8 *bssid,
174 enum ieee80211_tx_sync_type type)
175{
176 int ret = 0;
177
178 might_sleep();
179
180 check_sdata_in_driver(sdata);
181
182 trace_drv_tx_sync(local, sdata, bssid, type);
183 if (local->ops->tx_sync)
184 ret = local->ops->tx_sync(&local->hw, &sdata->vif,
185 bssid, type);
186 trace_drv_return_int(local, ret);
187 return ret;
188}
189
190static inline void drv_finish_tx_sync(struct ieee80211_local *local,
191 struct ieee80211_sub_if_data *sdata,
192 const u8 *bssid,
193 enum ieee80211_tx_sync_type type)
194{
195 might_sleep();
196
197 check_sdata_in_driver(sdata);
198
199 trace_drv_finish_tx_sync(local, sdata, bssid, type);
200 if (local->ops->finish_tx_sync)
201 local->ops->finish_tx_sync(&local->hw, &sdata->vif,
202 bssid, type);
203 trace_drv_return_void(local);
204}
205
206static inline u64 drv_prepare_multicast(struct ieee80211_local *local, 171static inline u64 drv_prepare_multicast(struct ieee80211_local *local,
207 struct netdev_hw_addr_list *mc_list) 172 struct netdev_hw_addr_list *mc_list)
208{ 173{
diff --git a/net/mac80211/driver-trace.h b/net/mac80211/driver-trace.h
index 384e2f08c187..7034209ad3f4 100644
--- a/net/mac80211/driver-trace.h
+++ b/net/mac80211/driver-trace.h
@@ -308,49 +308,6 @@ TRACE_EVENT(drv_bss_info_changed,
308 ) 308 )
309); 309);
310 310
311DECLARE_EVENT_CLASS(tx_sync_evt,
312 TP_PROTO(struct ieee80211_local *local,
313 struct ieee80211_sub_if_data *sdata,
314 const u8 *bssid,
315 enum ieee80211_tx_sync_type type),
316 TP_ARGS(local, sdata, bssid, type),
317
318 TP_STRUCT__entry(
319 LOCAL_ENTRY
320 VIF_ENTRY
321 __array(char, bssid, ETH_ALEN)
322 __field(u32, sync_type)
323 ),
324
325 TP_fast_assign(
326 LOCAL_ASSIGN;
327 VIF_ASSIGN;
328 memcpy(__entry->bssid, bssid, ETH_ALEN);
329 __entry->sync_type = type;
330 ),
331
332 TP_printk(
333 LOCAL_PR_FMT VIF_PR_FMT " bssid:%pM type:%d",
334 LOCAL_PR_ARG, VIF_PR_ARG, __entry->bssid, __entry->sync_type
335 )
336);
337
338DEFINE_EVENT(tx_sync_evt, drv_tx_sync,
339 TP_PROTO(struct ieee80211_local *local,
340 struct ieee80211_sub_if_data *sdata,
341 const u8 *bssid,
342 enum ieee80211_tx_sync_type type),
343 TP_ARGS(local, sdata, bssid, type)
344);
345
346DEFINE_EVENT(tx_sync_evt, drv_finish_tx_sync,
347 TP_PROTO(struct ieee80211_local *local,
348 struct ieee80211_sub_if_data *sdata,
349 const u8 *bssid,
350 enum ieee80211_tx_sync_type type),
351 TP_ARGS(local, sdata, bssid, type)
352);
353
354TRACE_EVENT(drv_prepare_multicast, 311TRACE_EVENT(drv_prepare_multicast,
355 TP_PROTO(struct ieee80211_local *local, int mc_count), 312 TP_PROTO(struct ieee80211_local *local, int mc_count),
356 313
diff --git a/net/mac80211/ieee80211_i.h b/net/mac80211/ieee80211_i.h
index 796b13bfc953..3c62ded64e32 100644
--- a/net/mac80211/ieee80211_i.h
+++ b/net/mac80211/ieee80211_i.h
@@ -388,7 +388,6 @@ struct ieee80211_mgd_auth_data {
388 388
389 u8 key[WLAN_KEY_LEN_WEP104]; 389 u8 key[WLAN_KEY_LEN_WEP104];
390 u8 key_len, key_idx; 390 u8 key_len, key_idx;
391 bool synced;
392 bool done; 391 bool done;
393 392
394 size_t ie_len; 393 size_t ie_len;
diff --git a/net/mac80211/mlme.c b/net/mac80211/mlme.c
index c08924aeac00..1d09df248c56 100644
--- a/net/mac80211/mlme.c
+++ b/net/mac80211/mlme.c
@@ -1770,11 +1770,6 @@ static void ieee80211_destroy_auth_data(struct ieee80211_sub_if_data *sdata,
1770 1770
1771 lockdep_assert_held(&sdata->u.mgd.mtx); 1771 lockdep_assert_held(&sdata->u.mgd.mtx);
1772 1772
1773 if (auth_data->synced)
1774 drv_finish_tx_sync(sdata->local, sdata,
1775 auth_data->bss->bssid,
1776 IEEE80211_TX_SYNC_AUTH);
1777
1778 if (!assoc) { 1773 if (!assoc) {
1779 sta_info_destroy_addr(sdata, auth_data->bss->bssid); 1774 sta_info_destroy_addr(sdata, auth_data->bss->bssid);
1780 1775
@@ -1862,10 +1857,6 @@ ieee80211_rx_mgmt_auth(struct ieee80211_sub_if_data *sdata,
1862 1857
1863 printk(KERN_DEBUG "%s: authenticated\n", sdata->name); 1858 printk(KERN_DEBUG "%s: authenticated\n", sdata->name);
1864 out: 1859 out:
1865 if (ifmgd->auth_data->synced)
1866 drv_finish_tx_sync(sdata->local, sdata, bssid,
1867 IEEE80211_TX_SYNC_AUTH);
1868 ifmgd->auth_data->synced = false;
1869 ifmgd->auth_data->done = true; 1860 ifmgd->auth_data->done = true;
1870 ifmgd->auth_data->timeout = jiffies + IEEE80211_AUTH_WAIT_ASSOC; 1861 ifmgd->auth_data->timeout = jiffies + IEEE80211_AUTH_WAIT_ASSOC;
1871 run_again(ifmgd, ifmgd->auth_data->timeout); 1862 run_again(ifmgd, ifmgd->auth_data->timeout);
@@ -2005,11 +1996,6 @@ static void ieee80211_destroy_assoc_data(struct ieee80211_sub_if_data *sdata,
2005 1996
2006 lockdep_assert_held(&sdata->u.mgd.mtx); 1997 lockdep_assert_held(&sdata->u.mgd.mtx);
2007 1998
2008 if (assoc_data->synced)
2009 drv_finish_tx_sync(sdata->local, sdata,
2010 assoc_data->bss->bssid,
2011 IEEE80211_TX_SYNC_ASSOC);
2012
2013 if (!assoc) { 1999 if (!assoc) {
2014 sta_info_destroy_addr(sdata, assoc_data->bss->bssid); 2000 sta_info_destroy_addr(sdata, assoc_data->bss->bssid);
2015 2001
@@ -2255,14 +2241,6 @@ ieee80211_rx_mgmt_assoc_resp(struct ieee80211_sub_if_data *sdata,
2255 } else { 2241 } else {
2256 printk(KERN_DEBUG "%s: associated\n", sdata->name); 2242 printk(KERN_DEBUG "%s: associated\n", sdata->name);
2257 2243
2258 /* tell driver about sync done first */
2259 if (assoc_data->synced) {
2260 drv_finish_tx_sync(sdata->local, sdata,
2261 assoc_data->bss->bssid,
2262 IEEE80211_TX_SYNC_ASSOC);
2263 assoc_data->synced = false;
2264 }
2265
2266 if (!ieee80211_assoc_success(sdata, *bss, mgmt, len)) { 2244 if (!ieee80211_assoc_success(sdata, *bss, mgmt, len)) {
2267 /* oops -- internal error -- send timeout for now */ 2245 /* oops -- internal error -- send timeout for now */
2268 ieee80211_destroy_assoc_data(sdata, true); 2246 ieee80211_destroy_assoc_data(sdata, true);
@@ -2747,14 +2725,6 @@ static int ieee80211_probe_auth(struct ieee80211_sub_if_data *sdata)
2747 if (WARN_ON_ONCE(!auth_data)) 2725 if (WARN_ON_ONCE(!auth_data))
2748 return -EINVAL; 2726 return -EINVAL;
2749 2727
2750 if (!auth_data->synced) {
2751 int ret = drv_tx_sync(local, sdata, auth_data->bss->bssid,
2752 IEEE80211_TX_SYNC_AUTH);
2753 if (ret)
2754 return ret;
2755 }
2756 auth_data->synced = true;
2757
2758 auth_data->tries++; 2728 auth_data->tries++;
2759 2729
2760 if (auth_data->tries > IEEE80211_AUTH_MAX_TRIES) { 2730 if (auth_data->tries > IEEE80211_AUTH_MAX_TRIES) {
@@ -2811,14 +2781,6 @@ static int ieee80211_do_assoc(struct ieee80211_sub_if_data *sdata)
2811 2781
2812 lockdep_assert_held(&sdata->u.mgd.mtx); 2782 lockdep_assert_held(&sdata->u.mgd.mtx);
2813 2783
2814 if (!assoc_data->synced) {
2815 int ret = drv_tx_sync(local, sdata, assoc_data->bss->bssid,
2816 IEEE80211_TX_SYNC_ASSOC);
2817 if (ret)
2818 return ret;
2819 }
2820 assoc_data->synced = true;
2821
2822 assoc_data->tries++; 2784 assoc_data->tries++;
2823 if (assoc_data->tries > IEEE80211_ASSOC_MAX_TRIES) { 2785 if (assoc_data->tries > IEEE80211_ASSOC_MAX_TRIES) {
2824 printk(KERN_DEBUG "%s: association with %pM timed out\n", 2786 printk(KERN_DEBUG "%s: association with %pM timed out\n",
@@ -3245,9 +3207,6 @@ int ieee80211_mgd_auth(struct ieee80211_sub_if_data *sdata,
3245 3207
3246 err = ieee80211_probe_auth(sdata); 3208 err = ieee80211_probe_auth(sdata);
3247 if (err) { 3209 if (err) {
3248 if (auth_data->synced)
3249 drv_finish_tx_sync(local, sdata, req->bss->bssid,
3250 IEEE80211_TX_SYNC_AUTH);
3251 sta_info_destroy_addr(sdata, req->bss->bssid); 3210 sta_info_destroy_addr(sdata, req->bss->bssid);
3252 goto err_clear; 3211 goto err_clear;
3253 } 3212 }