aboutsummaryrefslogtreecommitdiffstats
path: root/net/mac80211/ieee80211_i.h
diff options
context:
space:
mode:
Diffstat (limited to 'net/mac80211/ieee80211_i.h')
-rw-r--r--net/mac80211/ieee80211_i.h48
1 files changed, 41 insertions, 7 deletions
diff --git a/net/mac80211/ieee80211_i.h b/net/mac80211/ieee80211_i.h
index 241533e1bc03..1c8e24706685 100644
--- a/net/mac80211/ieee80211_i.h
+++ b/net/mac80211/ieee80211_i.h
@@ -317,6 +317,7 @@ enum ieee80211_sta_flags {
317 IEEE80211_STA_MFP_ENABLED = BIT(6), 317 IEEE80211_STA_MFP_ENABLED = BIT(6),
318 IEEE80211_STA_UAPSD_ENABLED = BIT(7), 318 IEEE80211_STA_UAPSD_ENABLED = BIT(7),
319 IEEE80211_STA_NULLFUNC_ACKED = BIT(8), 319 IEEE80211_STA_NULLFUNC_ACKED = BIT(8),
320 IEEE80211_STA_RESET_SIGNAL_AVE = BIT(9),
320}; 321};
321 322
322struct ieee80211_if_managed { 323struct ieee80211_if_managed {
@@ -327,7 +328,7 @@ struct ieee80211_if_managed {
327 struct work_struct work; 328 struct work_struct work;
328 struct work_struct monitor_work; 329 struct work_struct monitor_work;
329 struct work_struct chswitch_work; 330 struct work_struct chswitch_work;
330 struct work_struct beacon_loss_work; 331 struct work_struct beacon_connection_loss_work;
331 332
332 unsigned long probe_timeout; 333 unsigned long probe_timeout;
333 int probe_send_count; 334 int probe_send_count;
@@ -359,6 +360,24 @@ struct ieee80211_if_managed {
359 int wmm_last_param_set; 360 int wmm_last_param_set;
360 361
361 u8 use_4addr; 362 u8 use_4addr;
363
364 /* Signal strength from the last Beacon frame in the current BSS. */
365 int last_beacon_signal;
366
367 /*
368 * Weighted average of the signal strength from Beacon frames in the
369 * current BSS. This is in units of 1/16 of the signal unit to maintain
370 * accuracy and to speed up calculations, i.e., the value need to be
371 * divided by 16 to get the actual value.
372 */
373 int ave_beacon_signal;
374
375 /*
376 * Last Beacon frame signal strength average (ave_beacon_signal / 16)
377 * that triggered a cqm event. 0 indicates that no event has been
378 * generated for the current association.
379 */
380 int last_cqm_event_signal;
362}; 381};
363 382
364enum ieee80211_ibss_request { 383enum ieee80211_ibss_request {
@@ -745,10 +764,11 @@ struct ieee80211_local {
745 int scan_channel_idx; 764 int scan_channel_idx;
746 int scan_ies_len; 765 int scan_ies_len;
747 766
767 unsigned long leave_oper_channel_time;
748 enum mac80211_scan_state next_scan_state; 768 enum mac80211_scan_state next_scan_state;
749 struct delayed_work scan_work; 769 struct delayed_work scan_work;
750 struct ieee80211_sub_if_data *scan_sdata; 770 struct ieee80211_sub_if_data *scan_sdata;
751 enum nl80211_channel_type oper_channel_type; 771 enum nl80211_channel_type _oper_channel_type;
752 struct ieee80211_channel *oper_channel, *csa_channel; 772 struct ieee80211_channel *oper_channel, *csa_channel;
753 773
754 /* Temporary remain-on-channel for off-channel operations */ 774 /* Temporary remain-on-channel for off-channel operations */
@@ -979,7 +999,8 @@ int ieee80211_max_network_latency(struct notifier_block *nb,
979 unsigned long data, void *dummy); 999 unsigned long data, void *dummy);
980void ieee80211_sta_process_chanswitch(struct ieee80211_sub_if_data *sdata, 1000void ieee80211_sta_process_chanswitch(struct ieee80211_sub_if_data *sdata,
981 struct ieee80211_channel_sw_ie *sw_elem, 1001 struct ieee80211_channel_sw_ie *sw_elem,
982 struct ieee80211_bss *bss); 1002 struct ieee80211_bss *bss,
1003 u64 timestamp);
983void ieee80211_sta_quiesce(struct ieee80211_sub_if_data *sdata); 1004void ieee80211_sta_quiesce(struct ieee80211_sub_if_data *sdata);
984void ieee80211_sta_restart(struct ieee80211_sub_if_data *sdata); 1005void ieee80211_sta_restart(struct ieee80211_sub_if_data *sdata);
985 1006
@@ -1000,7 +1021,8 @@ void ieee80211_ibss_restart(struct ieee80211_sub_if_data *sdata);
1000/* scan/BSS handling */ 1021/* scan/BSS handling */
1001void ieee80211_scan_work(struct work_struct *work); 1022void ieee80211_scan_work(struct work_struct *work);
1002int ieee80211_request_internal_scan(struct ieee80211_sub_if_data *sdata, 1023int ieee80211_request_internal_scan(struct ieee80211_sub_if_data *sdata,
1003 const u8 *ssid, u8 ssid_len); 1024 const u8 *ssid, u8 ssid_len,
1025 struct ieee80211_channel *chan);
1004int ieee80211_request_scan(struct ieee80211_sub_if_data *sdata, 1026int ieee80211_request_scan(struct ieee80211_sub_if_data *sdata,
1005 struct cfg80211_scan_request *req); 1027 struct cfg80211_scan_request *req);
1006void ieee80211_scan_cancel(struct ieee80211_local *local); 1028void ieee80211_scan_cancel(struct ieee80211_local *local);
@@ -1078,8 +1100,6 @@ int ieee80211_send_smps_action(struct ieee80211_sub_if_data *sdata,
1078 enum ieee80211_smps_mode smps, const u8 *da, 1100 enum ieee80211_smps_mode smps, const u8 *da,
1079 const u8 *bssid); 1101 const u8 *bssid);
1080 1102
1081void ieee80211_sta_stop_rx_ba_session(struct ieee80211_sub_if_data *sdata, u8 *da,
1082 u16 tid, u16 initiator, u16 reason);
1083void __ieee80211_stop_rx_ba_session(struct sta_info *sta, u16 tid, 1103void __ieee80211_stop_rx_ba_session(struct sta_info *sta, u16 tid,
1084 u16 initiator, u16 reason); 1104 u16 initiator, u16 reason);
1085void ieee80211_sta_tear_down_BA_sessions(struct sta_info *sta); 1105void ieee80211_sta_tear_down_BA_sessions(struct sta_info *sta);
@@ -1155,7 +1175,7 @@ void ieee80211_send_nullfunc(struct ieee80211_local *local,
1155 int powersave); 1175 int powersave);
1156void ieee80211_sta_rx_notify(struct ieee80211_sub_if_data *sdata, 1176void ieee80211_sta_rx_notify(struct ieee80211_sub_if_data *sdata,
1157 struct ieee80211_hdr *hdr); 1177 struct ieee80211_hdr *hdr);
1158void ieee80211_beacon_loss_work(struct work_struct *work); 1178void ieee80211_beacon_connection_loss_work(struct work_struct *work);
1159 1179
1160void ieee80211_wake_queues_by_reason(struct ieee80211_hw *hw, 1180void ieee80211_wake_queues_by_reason(struct ieee80211_hw *hw,
1161 enum queue_stop_reason reason); 1181 enum queue_stop_reason reason);
@@ -1210,6 +1230,20 @@ int ieee80211_wk_remain_on_channel(struct ieee80211_sub_if_data *sdata,
1210int ieee80211_wk_cancel_remain_on_channel( 1230int ieee80211_wk_cancel_remain_on_channel(
1211 struct ieee80211_sub_if_data *sdata, u64 cookie); 1231 struct ieee80211_sub_if_data *sdata, u64 cookie);
1212 1232
1233/* channel management */
1234enum ieee80211_chan_mode {
1235 CHAN_MODE_UNDEFINED,
1236 CHAN_MODE_HOPPING,
1237 CHAN_MODE_FIXED,
1238};
1239
1240enum ieee80211_chan_mode
1241ieee80211_get_channel_mode(struct ieee80211_local *local,
1242 struct ieee80211_sub_if_data *ignore);
1243bool ieee80211_set_channel_type(struct ieee80211_local *local,
1244 struct ieee80211_sub_if_data *sdata,
1245 enum nl80211_channel_type chantype);
1246
1213#ifdef CONFIG_MAC80211_NOINLINE 1247#ifdef CONFIG_MAC80211_NOINLINE
1214#define debug_noinline noinline 1248#define debug_noinline noinline
1215#else 1249#else