cfg80211: reduce connect key caching struct size
[cascardo/linux.git] / net / wireless / core.h
index 025b7a5..5555e3c 100644 (file)
@@ -141,6 +141,18 @@ struct cfg80211_internal_bss {
        unsigned long refcount;
        atomic_t hold;
 
+       /* time at the start of the reception of the first octet of the
+        * timestamp field of the last beacon/probe received for this BSS.
+        * The time is the TSF of the BSS specified by %parent_bssid.
+        */
+       u64 parent_tsf;
+
+       /* the BSS according to which %parent_tsf is set. This is set to
+        * the BSS that the interface that requested the scan was connected to
+        * when the beacon/probe was received.
+        */
+       u8 parent_bssid[ETH_ALEN] __aligned(2);
+
        /* must be last because of priv member */
        struct cfg80211_bss pub;
 };
@@ -214,7 +226,7 @@ struct cfg80211_event {
                        size_t req_ie_len;
                        size_t resp_ie_len;
                        struct cfg80211_bss *bss;
-                       u16 status;
+                       int status; /* -1 = failed; 0..65535 = status code */
                } cr;
                struct {
                        const u8 *req_ie;
@@ -237,9 +249,9 @@ struct cfg80211_event {
 };
 
 struct cfg80211_cached_keys {
-       struct key_params params[6];
-       u8 data[6][WLAN_MAX_KEY_LEN];
-       int def, defmgmt;
+       struct key_params params[4];
+       u8 data[4][WLAN_KEY_LEN_WEP104];
+       int def;
 };
 
 enum cfg80211_chan_mode {
@@ -374,7 +386,7 @@ int cfg80211_connect(struct cfg80211_registered_device *rdev,
 void __cfg80211_connect_result(struct net_device *dev, const u8 *bssid,
                               const u8 *req_ie, size_t req_ie_len,
                               const u8 *resp_ie, size_t resp_ie_len,
-                              u16 status, bool wextev,
+                              int status, bool wextev,
                               struct cfg80211_bss *bss);
 void __cfg80211_disconnected(struct net_device *dev, const u8 *ie,
                             size_t ie_len, u16 reason, bool from_ap);