aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJouni Malinen <j@w1.fi>2003-07-27 17:52:41 (GMT)
committerJouni Malinen <j@w1.fi>2003-07-27 17:52:41 (GMT)
commitbfbe0abb4bacee733b5f8eb89ee706ff829de0db (patch)
tree95be7b45c15b1da3472f7ac584c75eb7a2e08d17
parentb498d4a32d7847ba669f36f6e8e224fa38882414 (diff)
downloadhostap-history-bfbe0abb4bacee733b5f8eb89ee706ff829de0db.zip
hostap-history-bfbe0abb4bacee733b5f8eb89ee706ff829de0db.tar.gz
hostap-history-bfbe0abb4bacee733b5f8eb89ee706ff829de0db.tar.bz2
Process beacon frames in kernel driver even when hostapd is used (this
updates AP tables and allows automatic WDS link generation).
-rw-r--r--ChangeLog2
-rw-r--r--driver/modules/hostap_80211_rx.c10
-rw-r--r--driver/modules/hostap_ap.c10
3 files changed, 17 insertions, 5 deletions
diff --git a/ChangeLog b/ChangeLog
index a723682..ff7346f 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -35,6 +35,8 @@ ChangeLog for Host AP driver for Intersil Prism2/2.5/3
scans and gives more control to user space programs using Linux
wireless extensions (see 'Roaming in station mode' section in
README file for more information)
+ * process beacon frames in kernel driver even when hostapd is used
+ (this updates AP tables and allows automatic WDS link generation)
2003-05-18 - v0.0.3
* redesigned RADIUS client implementation
diff --git a/driver/modules/hostap_80211_rx.c b/driver/modules/hostap_80211_rx.c
index fd9a49a..7551862 100644
--- a/driver/modules/hostap_80211_rx.c
+++ b/driver/modules/hostap_80211_rx.c
@@ -315,6 +315,16 @@ hostap_rx_frame_mgmt(local_info_t *local, struct sk_buff *skb,
}
if (local->hostapd && type == WLAN_FC_TYPE_MGMT) {
+ if (stype == WLAN_FC_STYPE_BEACON &&
+ local->iw_mode == IW_MODE_MASTER) {
+ struct sk_buff *skb2;
+ /* Process beacon frames also in kernel driver to
+ * update STA(AP) table statistics */
+ skb2 = skb_clone(skb, GFP_ATOMIC);
+ if (skb2)
+ hostap_rx(skb2->dev, skb2, rx_stats);
+ }
+
/* send management frames to the user space daemon for
* processing */
local->apdevstats.rx_packets++;
diff --git a/driver/modules/hostap_ap.c b/driver/modules/hostap_ap.c
index d2a763d..a481676 100644
--- a/driver/modules/hostap_ap.c
+++ b/driver/modules/hostap_ap.c
@@ -2308,6 +2308,11 @@ static void handle_ap_item(local_info_t *local, struct sk_buff *skb,
ap_handle_dropped_data(local, hdr);
goto done;
}
+
+ if (type == WLAN_FC_TYPE_MGMT && stype == WLAN_FC_STYPE_BEACON) {
+ handle_beacon(local, skb, rx_stats);
+ goto done;
+ }
#endif /* PRISM2_NO_KERNEL_IEEE80211_MGMT */
if (type == WLAN_FC_TYPE_CTRL && stype == WLAN_FC_STYPE_PSPOLL) {
@@ -2327,11 +2332,6 @@ static void handle_ap_item(local_info_t *local, struct sk_buff *skb,
goto done;
}
- if (stype == WLAN_FC_STYPE_BEACON) {
- handle_beacon(local, skb, rx_stats);
- goto done;
- }
-
if (memcmp(hdr->addr1, dev->dev_addr, ETH_ALEN)) {
PDEBUG(DEBUG_AP, "handle_ap_item - addr1(DA)=" MACSTR
" not own MAC\n", MAC2STR(hdr->addr1));