1
0
mirror of git://projects.qi-hardware.com/openwrt-xburst.git synced 2024-12-18 13:01:55 +02:00
openwrt-xburst/package/madwifi/patches/312-erpupdate.patch
nbd bcb54b3924 refresh madwifi patches, fix an issue with napi polling (thx SeG)
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@10511 3c298f89-4303-0410-b956-a3cf2f4a3e73
2008-02-20 21:26:21 +00:00

75 lines
2.8 KiB
Diff

Index: madwifi-trunk-r3314/net80211/ieee80211_beacon.c
===================================================================
--- madwifi-trunk-r3314.orig/net80211/ieee80211_beacon.c 2008-02-20 18:10:45.515108151 +0100
+++ madwifi-trunk-r3314/net80211/ieee80211_beacon.c 2008-02-20 18:10:50.491391734 +0100
@@ -542,10 +542,10 @@
vap->iv_flags &= ~IEEE80211_F_XRUPDATE;
}
#endif
- if ((ic->ic_flags_ext & IEEE80211_FEXT_ERPUPDATE) &&
+ if ((vap->iv_flags_ext & IEEE80211_FEXT_ERPUPDATE) &&
(bo->bo_erp != NULL)) {
(void)ieee80211_add_erp(bo->bo_erp, ic);
- ic->ic_flags_ext &= ~IEEE80211_FEXT_ERPUPDATE;
+ vap->iv_flags_ext &= ~IEEE80211_FEXT_ERPUPDATE;
}
}
/* if it is a mode change beacon for dynamic turbo case */
Index: madwifi-trunk-r3314/net80211/ieee80211_input.c
===================================================================
--- madwifi-trunk-r3314.orig/net80211/ieee80211_input.c 2008-02-20 18:10:49.723347963 +0100
+++ madwifi-trunk-r3314/net80211/ieee80211_input.c 2008-02-20 18:10:50.495391960 +0100
@@ -3431,9 +3431,12 @@
/* Assume no ERP IE == 11b AP */
if ((!has_erp || (has_erp && (scan.erp & IEEE80211_ERP_NON_ERP_PRESENT))) &&
!(ic->ic_flags & IEEE80211_F_USEPROT)) {
+ struct ieee80211vap *tmpvap;
ic->ic_flags |= IEEE80211_F_USEPROT;
- ic->ic_flags_ext |= IEEE80211_FEXT_ERPUPDATE;
+ TAILQ_FOREACH(tmpvap, &ic->ic_vaps, iv_next) {
+ tmpvap->iv_flags_ext |= IEEE80211_FEXT_ERPUPDATE;
+ }
}
}
Index: madwifi-trunk-r3314/net80211/ieee80211_node.c
===================================================================
--- madwifi-trunk-r3314.orig/net80211/ieee80211_node.c 2008-02-20 18:10:49.727348192 +0100
+++ madwifi-trunk-r3314/net80211/ieee80211_node.c 2008-02-20 18:10:50.507392644 +0100
@@ -2022,8 +2022,12 @@
}
/* Update ERP element if this is first non ERP station */
- if (ic->ic_nonerpsta == 1)
- ic->ic_flags_ext |= IEEE80211_FEXT_ERPUPDATE;
+ if (ic->ic_nonerpsta == 1) {
+ struct ieee80211vap *tmpvap;
+ TAILQ_FOREACH(tmpvap, &ic->ic_vaps, iv_next) {
+ tmpvap->iv_flags_ext |= IEEE80211_FEXT_ERPUPDATE;
+ }
+ }
} else
ni->ni_flags |= IEEE80211_NODE_ERP;
}
@@ -2226,6 +2230,8 @@
IEEE80211_NOTE(vap, IEEE80211_MSG_ASSOC, ni,
"non-ERP station leaves, count now %d", ic->ic_nonerpsta);
if (ic->ic_nonerpsta == 0) {
+ struct ieee80211vap *tmpvap;
+
IEEE80211_DPRINTF(vap, IEEE80211_MSG_ASSOC,
"%s: disable use of protection\n", __func__);
ic->ic_flags &= ~IEEE80211_F_USEPROT;
@@ -2237,7 +2243,9 @@
ic->ic_flags |= IEEE80211_F_SHPREAMBLE;
ic->ic_flags &= ~IEEE80211_F_USEBARKER;
}
- ic->ic_flags_ext |= IEEE80211_FEXT_ERPUPDATE;
+ TAILQ_FOREACH(tmpvap, &ic->ic_vaps, iv_next) {
+ tmpvap->iv_flags_ext |= IEEE80211_FEXT_ERPUPDATE;
+ }
}
}
}