svn commit: r195419 - projects/mesh11s/sys/net80211
Rui Paulo
rpaulo at FreeBSD.org
Mon Jul 6 21:23:44 UTC 2009
Author: rpaulo
Date: Mon Jul 6 21:23:43 2009
New Revision: 195419
URL: http://svn.freebsd.org/changeset/base/195419
Log:
Hide mesh details from output.c by adding mesh_discover().
Sponsored by: The FreeBSD Foundation
Modified:
projects/mesh11s/sys/net80211/ieee80211_mesh.c
projects/mesh11s/sys/net80211/ieee80211_mesh.h
projects/mesh11s/sys/net80211/ieee80211_output.c
Modified: projects/mesh11s/sys/net80211/ieee80211_mesh.c
==============================================================================
--- projects/mesh11s/sys/net80211/ieee80211_mesh.c Mon Jul 6 20:51:54 2009 (r195418)
+++ projects/mesh11s/sys/net80211/ieee80211_mesh.c Mon Jul 6 21:23:43 2009 (r195419)
@@ -2269,6 +2269,13 @@ ieee80211_add_meshpeer(uint8_t *frm, uin
return frm;
}
+struct ieee80211_node *
+ieee80211_mesh_discover(struct ieee80211vap *vap,
+ const uint8_t dest[IEEE80211_ADDR_LEN], struct mbuf *m)
+{
+ struct ieee80211_mesh_state *ms = vap->iv_mesh;
+ return ms->ms_ppath->mpp_discover(vap, dest, m);
+}
/*
* Compute an Airtime Link Metric for the link with this node.
*
Modified: projects/mesh11s/sys/net80211/ieee80211_mesh.h
==============================================================================
--- projects/mesh11s/sys/net80211/ieee80211_mesh.h Mon Jul 6 20:51:54 2009 (r195418)
+++ projects/mesh11s/sys/net80211/ieee80211_mesh.h Mon Jul 6 21:23:43 2009 (r195419)
@@ -31,8 +31,6 @@
#ifndef _NET80211_IEEE80211_MESH_H_
#define _NET80211_IEEE80211_MESH_H_
-#include <net80211/ieee80211_proto.h> /* for ieee80211_state */
-
/*
* 802.11s Information Elements.
*/
@@ -394,6 +392,7 @@ struct ieee80211_mesh_route {
/*
* Mesh Path Selection Protocol.
*/
+enum ieee80211_state;
struct ieee80211_mesh_proto_path {
char mpp_descr[12];
uint8_t mpp_ie[4];
@@ -488,5 +487,8 @@ struct ieee80211_scanparams;
void ieee80211_mesh_init_neighbor(struct ieee80211_node *,
const struct ieee80211_frame *,
const struct ieee80211_scanparams *);
+struct ieee80211_node *
+ ieee80211_mesh_discover(struct ieee80211vap *,
+ const uint8_t [IEEE80211_ADDR_LEN], struct mbuf *);
#endif /* _KERNEL */
#endif /* !_NET80211_IEEE80211_MESH_H_ */
Modified: projects/mesh11s/sys/net80211/ieee80211_output.c
==============================================================================
--- projects/mesh11s/sys/net80211/ieee80211_output.c Mon Jul 6 20:51:54 2009 (r195418)
+++ projects/mesh11s/sys/net80211/ieee80211_output.c Mon Jul 6 21:23:43 2009 (r195419)
@@ -239,13 +239,12 @@ ieee80211_start(struct ifnet *ifp)
continue;
}
} else {
- struct ieee80211_mesh_state *ms = vap->iv_mesh;
-
- ni = ms->ms_ppath->mpp_discover(vap, eh->ether_dhost, m);
+ ni = ieee80211_mesh_discover(vap, eh->ether_dhost, m);
if (ni == NULL) {
/*
- * NB: discover function holds/disposes
- * frame (e.g. queueing on path discovery).
+ * NB: ieee80211_mesh_discover function
+ * holds/disposes frame
+ * (e.g. queueing on path discovery).
*/
ifp->if_oerrors++;
continue;
More information about the svn-src-projects
mailing list