mac80211: protect rx-path with spinlock
[linux-2.6-block.git] / net / mac80211 / ieee80211_i.h
index e4ee16839c6d411f48898dbaf6b5662892ca6c2d..080cf0942ce7768b0797c33d0de62fa0d26ab428 100644 (file)
@@ -86,10 +86,6 @@ struct ieee80211_fragment_entry {
 
 
 struct ieee80211_bss {
-       /* don't want to look up all the time */
-       size_t ssid_len;
-       u8 ssid[IEEE80211_MAX_SSID_LEN];
-
        u32 device_ts;
 
        bool wmm_used;
@@ -391,6 +387,7 @@ struct ieee80211_if_managed {
        unsigned long probe_timeout;
        int probe_send_count;
        bool nullfunc_failed;
+       bool connection_loss;
 
        struct mutex mtx;
        struct cfg80211_bss *associated;
@@ -415,6 +412,10 @@ struct ieee80211_if_managed {
        bool beacon_crc_valid;
        u32 beacon_crc;
 
+       bool status_acked;
+       bool status_received;
+       __le16 status_fc;
+
        enum {
                IEEE80211_MFP_DISABLED,
                IEEE80211_MFP_OPTIONAL,
@@ -589,6 +590,11 @@ struct ieee80211_if_mesh {
        s64 sync_offset_clockdrift_max;
        spinlock_t sync_offset_lock;
        bool adjusting_tbtt;
+       /* mesh power save */
+       enum nl80211_mesh_power_mode nonpeer_pm;
+       int ps_peers_light_sleep;
+       int ps_peers_deep_sleep;
+       struct ps_data ps;
 };
 
 #ifdef CONFIG_MAC80211_MESH
@@ -952,14 +958,7 @@ struct ieee80211_local {
        struct sk_buff_head skb_queue;
        struct sk_buff_head skb_queue_unreliable;
 
-       /*
-        * Internal FIFO queue which is shared between multiple rx path
-        * stages. Its main task is to provide a serialization mechanism,
-        * so all rx handlers can enjoy having exclusive access to their
-        * private data structures.
-        */
-       struct sk_buff_head rx_skb_queue;
-       bool running_rx_handler;        /* protected by rx_skb_queue.lock */
+       spinlock_t rx_path_lock;
 
        /* Station data */
        /*
@@ -1184,6 +1183,7 @@ struct ieee802_11_elems {
        struct ieee80211_meshconf_ie *mesh_config;
        u8 *mesh_id;
        u8 *peering;
+       __le16 *awake_window;
        u8 *preq;
        u8 *prep;
        u8 *perr;
@@ -1284,6 +1284,8 @@ void ieee80211_sta_rx_queued_mgmt(struct ieee80211_sub_if_data *sdata,
 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_mgd_stop(struct ieee80211_sub_if_data *sdata);
+void ieee80211_mgd_conn_tx_status(struct ieee80211_sub_if_data *sdata,
+                                 __le16 fc, bool acked);
 
 /* IBSS code */
 void ieee80211_ibss_notify_scan_completed(struct ieee80211_local *local);
@@ -1544,7 +1546,8 @@ static inline void ieee80211_add_pending_skbs(struct ieee80211_local *local,
 void ieee80211_send_auth(struct ieee80211_sub_if_data *sdata,
                         u16 transaction, u16 auth_alg, u16 status,
                         u8 *extra, size_t extra_len, const u8 *bssid,
-                        const u8 *da, const u8 *key, u8 key_len, u8 key_idx);
+                        const u8 *da, const u8 *key, u8 key_len, u8 key_idx,
+                        u32 tx_flags);
 void ieee80211_send_deauth_disassoc(struct ieee80211_sub_if_data *sdata,
                                    const u8 *bssid, u16 stype, u16 reason,
                                    bool send_frame, u8 *frame_buf);
@@ -1561,7 +1564,7 @@ struct sk_buff *ieee80211_build_probe_req(struct ieee80211_sub_if_data *sdata,
 void ieee80211_send_probe_req(struct ieee80211_sub_if_data *sdata, u8 *dst,
                              const u8 *ssid, size_t ssid_len,
                              const u8 *ie, size_t ie_len,
-                             u32 ratemask, bool directed, bool no_cck,
+                             u32 ratemask, bool directed, u32 tx_flags,
                              struct ieee80211_channel *channel, bool scan);
 
 void ieee80211_sta_def_wmm_params(struct ieee80211_sub_if_data *sdata,