svn commit: r195293 - projects/mesh11s/sys/net80211

Sam Leffler sam at FreeBSD.org
Thu Jul 2 16:41:47 UTC 2009


Author: sam
Date: Thu Jul  2 16:41:46 2009
New Revision: 195293
URL: http://svn.freebsd.org/changeset/base/195293

Log:
  we cannot depend on the node address being stable between q and remove;
  use the hash of the mac address instead

Modified:
  projects/mesh11s/sys/net80211/ieee80211_wds.c

Modified: projects/mesh11s/sys/net80211/ieee80211_wds.c
==============================================================================
--- projects/mesh11s/sys/net80211/ieee80211_wds.c	Thu Jul  2 16:41:09 2009	(r195292)
+++ projects/mesh11s/sys/net80211/ieee80211_wds.c	Thu Jul  2 16:41:46 2009	(r195293)
@@ -104,7 +104,8 @@ wds_flush(struct ieee80211_node *ni)
 	struct mbuf *m, *next;
 	int8_t rssi, nf;
 
-	m = ieee80211_ageq_remove(&ic->ic_stageq, ni);
+	m = ieee80211_ageq_remove(&ic->ic_stageq,
+	    (void *)(uintptr_t) ieee80211_mac_hash(ic, ni->ni_macaddr));
 	if (m == NULL)
 		return;
 
@@ -325,6 +326,8 @@ ieee80211_dwds_discover(struct ieee80211
 	 * XXX handle overflow?
 	 * XXX per/vap beacon interval?
 	 */
+	m->m_pkthdr.rcvif = (void *)(uintptr_t)
+	    ieee80211_mac_hash(ic, ni->ni_macaddr);
 	(void) ieee80211_ageq_append(&ic->ic_stageq, m,
 	    ((ni->ni_intval * ic->ic_lintval) << 2) / 1024);
 	ieee80211_notify_wds_discover(ni);


More information about the svn-src-projects mailing list