svn commit: r195261 - projects/mesh11s/sys/net80211
Rui Paulo
rpaulo at FreeBSD.org
Wed Jul 1 22:15:05 UTC 2009
Author: rpaulo
Date: Wed Jul 1 22:15:04 2009
New Revision: 195261
URL: http://svn.freebsd.org/changeset/base/195261
Log:
Enable back ageq and automatic reverse path discovery now that they seem
to work ok.
Sponsored by: The FreeBSD Foundation
Modified:
projects/mesh11s/sys/net80211/ieee80211_hwmp.c
Modified: projects/mesh11s/sys/net80211/ieee80211_hwmp.c
==============================================================================
--- projects/mesh11s/sys/net80211/ieee80211_hwmp.c Wed Jul 1 22:06:12 2009 (r195260)
+++ projects/mesh11s/sys/net80211/ieee80211_hwmp.c Wed Jul 1 22:15:04 2009 (r195261)
@@ -606,7 +606,6 @@ hwmp_recv_preq(struct ieee80211vap *vap,
IEEE80211_ADDR_COPY(prep.prep_origaddr, vap->iv_myaddr);
prep.prep_origseq = hs->hs_seq++;
hwmp_send_prep(ni, vap->iv_myaddr, wh->i_addr2, &prep);
-#if 0
/*
* Build the reverse path, if we don't have it already.
*/
@@ -617,7 +616,6 @@ hwmp_recv_preq(struct ieee80211vap *vap,
ieee80211_hwmp_discover(vap, dest, NULL);
} else if (IEEE80211_ADDR_EQ(rt->rt_nexthop, invalidaddr))
ieee80211_hwmp_discover(vap, rt->rt_dest, NULL);
-#endif
return;
}
rt = hwmp_rt_find(vap, PREQ_TADDR(0));
@@ -767,6 +765,9 @@ hwmp_recv_prep(struct ieee80211vap *vap,
{
struct ieee80211_mesh_state *ms = vap->iv_mesh;
struct ieee80211_hwmp_route *rt = NULL;
+ struct ieee80211com *ic = vap->iv_ic;
+ struct ifnet *ifp = vap->iv_ifp;
+ struct mbuf *m, *next;
/*
* Acceptance criteria: if the PREP was not generated by us and
@@ -836,28 +837,22 @@ hwmp_recv_prep(struct ieee80211vap *vap,
* XXX: If it's NOT for us and the AE bit is set,
* update the proxy information table.
*/
-#if 0
- if (rt != NULL) {
- struct ieee80211com *ic = vap->iv_ic;
- struct ifnet *ifp = vap->iv_ifp;
- struct mbuf *m, *next;
- /*
- * Check for frames queued awaiting path discovery.
- * XXX probably can tell exactly and avoid remove call
- * NB: hash may have false matches, if so they will get
- * stuck back on the stageq because there won't be
- * a path.
- */
- m = ieee80211_ageq_remove(&ic->ic_stageq,
- (struct ieee80211_node *)(uintptr_t)
- ieee80211_mac_hash(ic, rt->rt_dest));
- for (; m != NULL; m = next) {
- next = m->m_nextpkt;
- m->m_nextpkt = NULL;
- ifp->if_transmit(ifp, m);
- }
+
+ /*
+ * Check for frames queued awaiting path discovery.
+ * XXX probably can tell exactly and avoid remove call
+ * NB: hash may have false matches, if so they will get
+ * stuck back on the stageq because there won't be
+ * a path.
+ */
+ m = ieee80211_ageq_remove(&ic->ic_stageq,
+ (struct ieee80211_node *)(uintptr_t)
+ ieee80211_mac_hash(ic, rt->rt_dest));
+ for (; m != NULL; m = next) {
+ next = m->m_nextpkt;
+ m->m_nextpkt = NULL;
+ ifp->if_transmit(ifp, m);
}
-#endif
}
static inline int
@@ -1139,7 +1134,6 @@ done:
if (ni == NULL && m != NULL) {
IEEE80211_DISCARD_MAC(vap, IEEE80211_MSG_HWMP,
dest, NULL, "%s", "no valid path to this node");
-#if 0
if (sendpreq) {
struct ieee80211com *ic = vap->iv_ic;
/*
@@ -1153,7 +1147,6 @@ done:
ieee80211_ageq_append(&ic->ic_stageq, m,
IEEE80211_INACT_WAIT);
} else
-#endif
m_freem(m);
}
return ni;
More information about the svn-src-projects
mailing list