Defines | Enumerations | Functions | Variables
mlme.c File Reference
#include <linux/delay.h>
#include <linux/if_ether.h>
#include <linux/skbuff.h>
#include <linux/if_arp.h>
#include <linux/etherdevice.h>
#include <linux/moduleparam.h>
#include <linux/rtnetlink.h>
#include <linux/pm_qos.h>
#include <linux/crc32.h>
#include <linux/slab.h>
#include <linux/export.h>
#include <net/mac80211.h>
#include <asm/unaligned.h>
#include "ieee80211_i.h"
#include "driver-ops.h"
#include "rate.h"
#include "led.h"
Include dependency graph for kernel-3.2/mlme.c:

Go to the source code of this file.

Defines

#define IEEE80211_BEACON_LOSS_COUNT   7
#define IEEE80211_CONNECTION_IDLE_TIME   (30 * HZ)
#define IEEE80211_SIGNAL_AVE_MIN_COUNT   4
#define IEEE80211_SIGNAL_AVE_WEIGHT   3
#define TMR_RUNNING_CHANSW   1
#define TMR_RUNNING_TIMER   0

Enumerations

enum  rx_mgmt_action {
  RX_MGMT_NONE, RX_MGMT_CFG80211_DEAUTH, RX_MGMT_CFG80211_DISASSOC, RX_MGMT_NONE,
  RX_MGMT_CFG80211_DEAUTH, RX_MGMT_CFG80211_DISASSOC, RX_MGMT_CFG80211_RX_AUTH, RX_MGMT_CFG80211_RX_ASSOC,
  RX_MGMT_CFG80211_ASSOC_TIMEOUT
}

Functions

static void __ieee80211_connection_loss (struct ieee80211_sub_if_data *sdata)
static void ASSERT_MGD_MTX (struct ieee80211_if_managed *ifmgd)
static int ecw2cw (int ecw)
 EXPORT_SYMBOL (ieee80211_chswitch_done)
 EXPORT_SYMBOL (ieee80211_enable_dyn_ps)
 EXPORT_SYMBOL (ieee80211_disable_dyn_ps)
 EXPORT_SYMBOL (ieee80211_ap_probereq_get)
 EXPORT_SYMBOL (ieee80211_beacon_loss)
 EXPORT_SYMBOL (ieee80211_connection_loss)
 EXPORT_SYMBOL (ieee80211_cqm_rssi_notify)
 EXPORT_SYMBOL (ieee80211_get_operstate)
struct sk_buffieee80211_ap_probereq_get (struct ieee80211_hw *hw, struct ieee80211_vif *vif)
static enum work_done_result ieee80211_assoc_done (struct ieee80211_work *wk, struct sk_buff *skb)
static bool ieee80211_assoc_success (struct ieee80211_work *wk, struct ieee80211_mgmt *mgmt, size_t len)
void ieee80211_beacon_connection_loss_work (struct work_struct *work)
void ieee80211_beacon_loss (struct ieee80211_vif *vif)
static void ieee80211_change_ps (struct ieee80211_local *local)
void ieee80211_chswitch_done (struct ieee80211_vif *vif, bool success)
static void ieee80211_chswitch_timer (unsigned long data)
static void ieee80211_chswitch_work (struct work_struct *work)
void ieee80211_connection_loss (struct ieee80211_vif *vif)
void ieee80211_cqm_rssi_notify (struct ieee80211_vif *vif, enum nl80211_cqm_rssi_threshold_event rssi_event, gfp_t gfp)
void ieee80211_disable_dyn_ps (struct ieee80211_vif *vif)
void ieee80211_dynamic_ps_disable_work (struct work_struct *work)
void ieee80211_dynamic_ps_enable_work (struct work_struct *work)
void ieee80211_dynamic_ps_timer (unsigned long data)
void ieee80211_enable_dyn_ps (struct ieee80211_vif *vif)
static u32 ieee80211_enable_ht (struct ieee80211_sub_if_data *sdata, struct ieee80211_ht_info *hti, const u8 *bssid, u16 ap_ht_cap_flags, bool beacon_htcap_ie)
static void ieee80211_enable_ps (struct ieee80211_local *local, struct ieee80211_sub_if_data *sdata)
unsigned char ieee80211_get_operstate (struct ieee80211_vif *vif)
static u32 ieee80211_handle_bss_capability (struct ieee80211_sub_if_data *sdata, u16 capab, bool erp_valid, u8 erp)
static void ieee80211_handle_pwr_constr (struct ieee80211_sub_if_data *sdata, u16 capab_info, u8 *pwr_constr_elem, u8 pwr_constr_elem_len)
int ieee80211_max_network_latency (struct notifier_block *nb, unsigned long data, void *dummy)
int ieee80211_mgd_assoc (struct ieee80211_sub_if_data *sdata, struct cfg80211_assoc_request *req)
int ieee80211_mgd_auth (struct ieee80211_sub_if_data *sdata, struct cfg80211_auth_request *req)
int ieee80211_mgd_deauth (struct ieee80211_sub_if_data *sdata, struct cfg80211_deauth_request *req, void *cookie)
int ieee80211_mgd_disassoc (struct ieee80211_sub_if_data *sdata, struct cfg80211_disassoc_request *req, void *cookie)
static void ieee80211_mgd_probe_ap (struct ieee80211_sub_if_data *sdata, bool beacon)
static void ieee80211_mgd_probe_ap_send (struct ieee80211_sub_if_data *sdata)
void ieee80211_mlme_notify_scan_completed (struct ieee80211_local *local)
static bool ieee80211_powersave_allowed (struct ieee80211_sub_if_data *sdata)
static int ieee80211_pre_assoc (struct ieee80211_sub_if_data *sdata, u8 *bssid)
static enum work_done_result ieee80211_probe_auth_done (struct ieee80211_work *wk, struct sk_buff *skb)
void ieee80211_recalc_ps (struct ieee80211_local *local, s32 latency)
static void ieee80211_reset_ap_probe (struct ieee80211_sub_if_data *sdata)
static void ieee80211_restart_sta_timer (struct ieee80211_sub_if_data *sdata)
static void ieee80211_rx_bss_info (struct ieee80211_sub_if_data *sdata, struct ieee80211_mgmt *mgmt, size_t len, struct ieee80211_rx_status *rx_status, struct ieee802_11_elems *elems, bool beacon)
static void ieee80211_rx_mgmt_beacon (struct ieee80211_sub_if_data *sdata, struct ieee80211_mgmt *mgmt, size_t len, struct ieee80211_rx_status *rx_status)
static enum rx_mgmt_action
__must_check 
ieee80211_rx_mgmt_deauth (struct ieee80211_sub_if_data *sdata, struct ieee80211_mgmt *mgmt, size_t len)
static enum rx_mgmt_action
__must_check 
ieee80211_rx_mgmt_disassoc (struct ieee80211_sub_if_data *sdata, struct ieee80211_mgmt *mgmt, size_t len)
static void ieee80211_rx_mgmt_probe_resp (struct ieee80211_sub_if_data *sdata, struct sk_buff *skb)
static void ieee80211_send_4addr_nullfunc (struct ieee80211_local *local, struct ieee80211_sub_if_data *sdata)
static void ieee80211_send_deauth_disassoc (struct ieee80211_sub_if_data *sdata, const u8 *bssid, u16 stype, u16 reason, void *cookie, bool send_frame)
void ieee80211_send_nullfunc (struct ieee80211_local *local, struct ieee80211_sub_if_data *sdata, int powersave)
void ieee80211_send_pspoll (struct ieee80211_local *local, struct ieee80211_sub_if_data *sdata)
static void ieee80211_set_associated (struct ieee80211_sub_if_data *sdata, struct cfg80211_bss *cbss, u32 bss_info_changed)
static void ieee80211_set_disassoc (struct ieee80211_sub_if_data *sdata, bool remove_sta, bool tx)
static void ieee80211_sta_bcn_mon_timer (unsigned long data)
static void ieee80211_sta_conn_mon_timer (unsigned long data)
static void ieee80211_sta_connection_lost (struct ieee80211_sub_if_data *sdata, u8 *bssid, u8 reason)
static void ieee80211_sta_monitor_work (struct work_struct *work)
void ieee80211_sta_process_chanswitch (struct ieee80211_sub_if_data *sdata, struct ieee80211_channel_sw_ie *sw_elem, struct ieee80211_bss *bss, u64 timestamp)
void ieee80211_sta_reset_beacon_monitor (struct ieee80211_sub_if_data *sdata)
void ieee80211_sta_reset_conn_monitor (struct ieee80211_sub_if_data *sdata)
void ieee80211_sta_rx_notify (struct ieee80211_sub_if_data *sdata, struct ieee80211_hdr *hdr)
void ieee80211_sta_rx_queued_mgmt (struct ieee80211_sub_if_data *sdata, struct sk_buff *skb)
void ieee80211_sta_setup_sdata (struct ieee80211_sub_if_data *sdata)
static void ieee80211_sta_timer (unsigned long data)
void ieee80211_sta_tx_notify (struct ieee80211_sub_if_data *sdata, struct ieee80211_hdr *hdr, bool ack)
static void ieee80211_sta_wmm_params (struct ieee80211_local *local, struct ieee80211_sub_if_data *sdata, u8 *wmm_param, size_t wmm_param_len)
void ieee80211_sta_work (struct ieee80211_sub_if_data *sdata)
 module_param (max_nullfunc_tries, int, 0644)
 module_param (max_probe_tries, int, 0644)
 module_param (probe_wait_ms, int, 0644)
 MODULE_PARM_DESC (max_nullfunc_tries,"Maximum nullfunc tx tries before disconnecting (reason 4).")
 MODULE_PARM_DESC (max_probe_tries,"Maximum probe tries before disconnecting (reason 4).")
 MODULE_PARM_DESC (probe_wait_ms,"Maximum time(ms) to wait for probe response"" before disconnecting (reason 4).")
static void run_again (struct ieee80211_if_managed *ifmgd, unsigned long timeout)

Variables

static const u64 care_about_ies
static int max_nullfunc_tries = 2
static int max_probe_tries = 5
static int probe_wait_ms = 500

Define Documentation

Definition at line 51 of file kernel-3.2/mlme.c.

#define IEEE80211_CONNECTION_IDLE_TIME   (30 * HZ)

Definition at line 57 of file kernel-3.2/mlme.c.

Definition at line 80 of file kernel-3.2/mlme.c.

Definition at line 74 of file kernel-3.2/mlme.c.

#define TMR_RUNNING_CHANSW   1

Definition at line 83 of file kernel-3.2/mlme.c.

#define TMR_RUNNING_TIMER   0

Definition at line 82 of file kernel-3.2/mlme.c.


Enumeration Type Documentation

Enumerator:
RX_MGMT_NONE 
RX_MGMT_CFG80211_DEAUTH 
RX_MGMT_CFG80211_DISASSOC 
RX_MGMT_NONE 
RX_MGMT_CFG80211_DEAUTH 
RX_MGMT_CFG80211_DISASSOC 
RX_MGMT_CFG80211_RX_AUTH 
RX_MGMT_CFG80211_RX_ASSOC 
RX_MGMT_CFG80211_ASSOC_TIMEOUT 

Definition at line 91 of file kernel-3.2/mlme.c.


Function Documentation

static void __ieee80211_connection_loss ( struct ieee80211_sub_if_data sdata) [static]

Definition at line 1342 of file kernel-3.2/mlme.c.

static void ASSERT_MGD_MTX ( struct ieee80211_if_managed ifmgd) [inline, static]

Definition at line 103 of file kernel-3.2/mlme.c.

static int ecw2cw ( int  ecw) [static]

Definition at line 153 of file kernel-3.2/mlme.c.

struct sk_buff* ieee80211_ap_probereq_get ( struct ieee80211_hw *  hw,
struct ieee80211_vif *  vif 
) [read]

Definition at line 1317 of file kernel-3.2/mlme.c.

static enum work_done_result ieee80211_assoc_done ( struct ieee80211_work wk,
struct sk_buff skb 
) [static]

Definition at line 2519 of file kernel-3.2/mlme.c.

static bool ieee80211_assoc_success ( struct ieee80211_work wk,
struct ieee80211_mgmt *  mgmt,
size_t  len 
) [static]

Definition at line 1472 of file kernel-3.2/mlme.c.

void ieee80211_beacon_connection_loss_work ( struct work_struct *  work)

Definition at line 1375 of file kernel-3.2/mlme.c.

void ieee80211_beacon_loss ( struct ieee80211_vif *  vif)

Definition at line 1387 of file kernel-3.2/mlme.c.

static void ieee80211_change_ps ( struct ieee80211_local local) [static]

Definition at line 619 of file kernel-3.2/mlme.c.

void ieee80211_chswitch_done ( struct ieee80211_vif *  vif,
bool  success 
)

Definition at line 435 of file kernel-3.2/mlme.c.

static void ieee80211_chswitch_timer ( unsigned long  data) [static]

Definition at line 458 of file kernel-3.2/mlme.c.

static void ieee80211_chswitch_work ( struct work_struct *  work) [static]

Definition at line 402 of file kernel-3.2/mlme.c.

void ieee80211_connection_loss ( struct ieee80211_vif *  vif)

Definition at line 1399 of file kernel-3.2/mlme.c.

void ieee80211_cqm_rssi_notify ( struct ieee80211_vif *  vif,
enum nl80211_cqm_rssi_threshold_event  rssi_event,
gfp_t  gfp 
)

Definition at line 2845 of file kernel-3.2/mlme.c.

void ieee80211_disable_dyn_ps ( struct ieee80211_vif *  vif)

Definition at line 571 of file kernel-3.2/mlme.c.

void ieee80211_dynamic_ps_disable_work ( struct work_struct *  work)

Definition at line 757 of file kernel-3.2/mlme.c.

void ieee80211_dynamic_ps_enable_work ( struct work_struct *  work)

Definition at line 772 of file kernel-3.2/mlme.c.

void ieee80211_dynamic_ps_timer ( unsigned long  data)

Definition at line 847 of file kernel-3.2/mlme.c.

void ieee80211_enable_dyn_ps ( struct ieee80211_vif *  vif)

Definition at line 556 of file kernel-3.2/mlme.c.

static u32 ieee80211_enable_ht ( struct ieee80211_sub_if_data sdata,
struct ieee80211_ht_info *  hti,
const u8 bssid,
u16  ap_ht_cap_flags,
bool  beacon_htcap_ie 
) [static]

Definition at line 163 of file kernel-3.2/mlme.c.

static void ieee80211_enable_ps ( struct ieee80211_local local,
struct ieee80211_sub_if_data sdata 
) [static]

Definition at line 590 of file kernel-3.2/mlme.c.

unsigned char ieee80211_get_operstate ( struct ieee80211_vif *  vif)

Definition at line 2857 of file kernel-3.2/mlme.c.

static u32 ieee80211_handle_bss_capability ( struct ieee80211_sub_if_data sdata,
u16  capab,
bool  erp_valid,
u8  erp 
) [static]

Definition at line 958 of file kernel-3.2/mlme.c.

static void ieee80211_handle_pwr_constr ( struct ieee80211_sub_if_data sdata,
u16  capab_info,
u8 pwr_constr_elem,
u8  pwr_constr_elem_len 
) [static]

Definition at line 536 of file kernel-3.2/mlme.c.

int ieee80211_max_network_latency ( struct notifier_block *  nb,
unsigned long  data,
void *  dummy 
)

Definition at line 2382 of file kernel-3.2/mlme.c.

int ieee80211_mgd_assoc ( struct ieee80211_sub_if_data sdata,
struct cfg80211_assoc_request *  req 
)

Definition at line 2581 of file kernel-3.2/mlme.c.

int ieee80211_mgd_auth ( struct ieee80211_sub_if_data sdata,
struct cfg80211_auth_request *  req 
)

Definition at line 2429 of file kernel-3.2/mlme.c.

int ieee80211_mgd_deauth ( struct ieee80211_sub_if_data sdata,
struct cfg80211_deauth_request *  req,
void *  cookie 
)

Definition at line 2716 of file kernel-3.2/mlme.c.

int ieee80211_mgd_disassoc ( struct ieee80211_sub_if_data sdata,
struct cfg80211_disassoc_request *  req,
void *  cookie 
)

Definition at line 2805 of file kernel-3.2/mlme.c.

static void ieee80211_mgd_probe_ap ( struct ieee80211_sub_if_data sdata,
bool  beacon 
) [static]

Definition at line 1258 of file kernel-3.2/mlme.c.

static void ieee80211_mgd_probe_ap_send ( struct ieee80211_sub_if_data sdata) [static]

Definition at line 1222 of file kernel-3.2/mlme.c.

Definition at line 2371 of file kernel-3.2/mlme.c.

static bool ieee80211_powersave_allowed ( struct ieee80211_sub_if_data sdata) [static]

Definition at line 633 of file kernel-3.2/mlme.c.

static int ieee80211_pre_assoc ( struct ieee80211_sub_if_data sdata,
u8 bssid 
) [static]

Definition at line 2497 of file kernel-3.2/mlme.c.

static enum work_done_result ieee80211_probe_auth_done ( struct ieee80211_work wk,
struct sk_buff skb 
) [static]

Definition at line 2399 of file kernel-3.2/mlme.c.

void ieee80211_recalc_ps ( struct ieee80211_local local,
s32  latency 
)

Definition at line 665 of file kernel-3.2/mlme.c.

static void ieee80211_reset_ap_probe ( struct ieee80211_sub_if_data sdata) [static]

Definition at line 1174 of file kernel-3.2/mlme.c.

static void ieee80211_restart_sta_timer ( struct ieee80211_sub_if_data sdata) [static]

Definition at line 2264 of file kernel-3.2/mlme.c.

static void ieee80211_rx_bss_info ( struct ieee80211_sub_if_data sdata,
struct ieee80211_mgmt *  mgmt,
size_t  len,
struct ieee80211_rx_status rx_status,
struct ieee802_11_elems elems,
bool  beacon 
) [static]

Definition at line 1677 of file kernel-3.2/mlme.c.

static void ieee80211_rx_mgmt_beacon ( struct ieee80211_sub_if_data sdata,
struct ieee80211_mgmt *  mgmt,
size_t  len,
struct ieee80211_rx_status rx_status 
) [static]

Definition at line 1783 of file kernel-3.2/mlme.c.

static enum rx_mgmt_action __must_check ieee80211_rx_mgmt_deauth ( struct ieee80211_sub_if_data sdata,
struct ieee80211_mgmt *  mgmt,
size_t  len 
) [static]

Definition at line 1413 of file kernel-3.2/mlme.c.

static enum rx_mgmt_action __must_check ieee80211_rx_mgmt_disassoc ( struct ieee80211_sub_if_data sdata,
struct ieee80211_mgmt *  mgmt,
size_t  len 
) [static]

Definition at line 1442 of file kernel-3.2/mlme.c.

static void ieee80211_rx_mgmt_probe_resp ( struct ieee80211_sub_if_data sdata,
struct sk_buff skb 
) [static]

Definition at line 1732 of file kernel-3.2/mlme.c.

static void ieee80211_send_4addr_nullfunc ( struct ieee80211_local local,
struct ieee80211_sub_if_data sdata 
) [static]

Definition at line 371 of file kernel-3.2/mlme.c.

static void ieee80211_send_deauth_disassoc ( struct ieee80211_sub_if_data sdata,
const u8 bssid,
u16  stype,
u16  reason,
void *  cookie,
bool  send_frame 
) [static]

Definition at line 286 of file kernel-3.2/mlme.c.

void ieee80211_send_nullfunc ( struct ieee80211_local local,
struct ieee80211_sub_if_data sdata,
int  powersave 
)

Definition at line 347 of file kernel-3.2/mlme.c.

void ieee80211_send_pspoll ( struct ieee80211_local local,
struct ieee80211_sub_if_data sdata 
)

Definition at line 330 of file kernel-3.2/mlme.c.

static void ieee80211_set_associated ( struct ieee80211_sub_if_data sdata,
struct cfg80211_bss *  cbss,
u32  bss_info_changed 
) [static]

Definition at line 997 of file kernel-3.2/mlme.c.

static void ieee80211_set_disassoc ( struct ieee80211_sub_if_data sdata,
bool  remove_sta,
bool  tx 
) [static]

Definition at line 1066 of file kernel-3.2/mlme.c.

static void ieee80211_sta_bcn_mon_timer ( unsigned long  data) [static]

Definition at line 2229 of file kernel-3.2/mlme.c.

static void ieee80211_sta_conn_mon_timer ( unsigned long  data) [static]

Definition at line 2242 of file kernel-3.2/mlme.c.

static void ieee80211_sta_connection_lost ( struct ieee80211_sub_if_data sdata,
u8 bssid,
u8  reason 
) [static]

Definition at line 2120 of file kernel-3.2/mlme.c.

static void ieee80211_sta_monitor_work ( struct work_struct *  work) [static]

Definition at line 2255 of file kernel-3.2/mlme.c.

void ieee80211_sta_process_chanswitch ( struct ieee80211_sub_if_data sdata,
struct ieee80211_channel_sw_ie *  sw_elem,
struct ieee80211_bss bss,
u64  timestamp 
)

Definition at line 472 of file kernel-3.2/mlme.c.

Definition at line 128 of file kernel-3.2/mlme.c.

Definition at line 137 of file kernel-3.2/mlme.c.

void ieee80211_sta_rx_notify ( struct ieee80211_sub_if_data sdata,
struct ieee80211_hdr hdr 
)

Definition at line 1157 of file kernel-3.2/mlme.c.

void ieee80211_sta_rx_queued_mgmt ( struct ieee80211_sub_if_data sdata,
struct sk_buff skb 
)

Definition at line 2001 of file kernel-3.2/mlme.c.

Definition at line 2341 of file kernel-3.2/mlme.c.

static void ieee80211_sta_timer ( unsigned long  data) [static]

Definition at line 2105 of file kernel-3.2/mlme.c.

void ieee80211_sta_tx_notify ( struct ieee80211_sub_if_data sdata,
struct ieee80211_hdr hdr,
bool  ack 
)

Definition at line 1203 of file kernel-3.2/mlme.c.

static void ieee80211_sta_wmm_params ( struct ieee80211_local local,
struct ieee80211_sub_if_data sdata,
u8 wmm_param,
size_t  wmm_param_len 
) [static]

Definition at line 858 of file kernel-3.2/mlme.c.

void ieee80211_sta_work ( struct ieee80211_sub_if_data sdata)

Definition at line 2144 of file kernel-3.2/mlme.c.

module_param ( max_nullfunc_tries  ,
int  ,
0644   
)
module_param ( max_probe_tries  ,
int  ,
0644   
)
module_param ( probe_wait_ms  ,
int  ,
0644   
)
MODULE_PARM_DESC ( max_nullfunc_tries  ,
"Maximum nullfunc tx tries before disconnecting (reason 4)."   
)
MODULE_PARM_DESC ( max_probe_tries  ,
"Maximum probe tries before disconnecting (reason 4)."   
)
MODULE_PARM_DESC ( probe_wait_ms  ,
"Maximum time(ms) to wait for probe response"" before disconnecting (reason 4)."   
)
static void run_again ( struct ieee80211_if_managed ifmgd,
unsigned long  timeout 
) [static]

Definition at line 118 of file kernel-3.2/mlme.c.


Variable Documentation

const u64 care_about_ies [static]
Initial value:
        (1ULL << WLAN_EID_COUNTRY) |
        (1ULL << WLAN_EID_ERP_INFO) |
        (1ULL << WLAN_EID_CHANNEL_SWITCH) |
        (1ULL << WLAN_EID_PWR_CONSTRAINT) |
        (1ULL << WLAN_EID_HT_CAPABILITY) |
        (1ULL << WLAN_EID_HT_INFORMATION)

Definition at line 1775 of file kernel-3.2/mlme.c.

int max_nullfunc_tries = 2 [static]

Definition at line 33 of file kernel-3.2/mlme.c.

int max_probe_tries = 5 [static]

Definition at line 38 of file kernel-3.2/mlme.c.

int probe_wait_ms = 500 [static]

Definition at line 63 of file kernel-3.2/mlme.c.



ros_rt_wmp
Author(s): Danilo Tardioli, dantard@unizar.es
autogenerated on Mon Oct 6 2014 08:27:13