fedora core 6 1.2949 + vserver 2.2.0
[linux-2.6.git] / net / ieee80211 / softmac / ieee80211softmac_io.c
index 3b67d19..b969310 100644 (file)
@@ -467,3 +467,22 @@ ieee80211softmac_send_mgt_frame(struct ieee80211softmac_device *mac,
        kfree(pkt);
        return 0;
 }
+
+/* Beacon handling */
+int ieee80211softmac_handle_beacon(struct net_device *dev,
+       struct ieee80211_beacon *beacon,
+       struct ieee80211_network *network)
+{
+       struct ieee80211softmac_device *mac = ieee80211_priv(dev);
+
+       /* This might race, but we don't really care and it's not worth
+        * adding heavyweight locking in this fastpath.
+        */
+       if (mac->associnfo.associated) {
+               if (memcmp(network->bssid, mac->associnfo.bssid, ETH_ALEN) == 0)
+                       ieee80211softmac_process_erp(mac, network->erp_value);
+       }
+
+       return 0;
+}
+