svn commit: r191622 - projects/mesh11s/sys/net80211
Rui Paulo
rpaulo at FreeBSD.org
Tue Apr 28 11:30:19 UTC 2009
Author: rpaulo
Date: Tue Apr 28 11:30:18 2009
New Revision: 191622
URL: http://svn.freebsd.org/changeset/base/191622
Log:
Second try at filling up a mesh conf IE. This now avoids any endianess
problems and, as a result, Linux is now trying to establish a link with
us!
Sponsored by: The FreeBSD Foundation
Modified:
projects/mesh11s/sys/net80211/ieee80211_mesh.c
projects/mesh11s/sys/net80211/ieee80211_mesh.h
Modified: projects/mesh11s/sys/net80211/ieee80211_mesh.c
==============================================================================
--- projects/mesh11s/sys/net80211/ieee80211_mesh.c Tue Apr 28 11:10:33 2009 (r191621)
+++ projects/mesh11s/sys/net80211/ieee80211_mesh.c Tue Apr 28 11:30:18 2009 (r191622)
@@ -504,9 +504,9 @@ ieee80211_add_meshconf(uint8_t *frm, str
.conf_ver = IEEE80211_MESHCONF_VERSION,
.conf_pselid = IEEE80211_MESHCONF_HWMP,
.conf_pmetid = IEEE80211_MESHCONF_AIRTIME,
- .conf_ccid = IEEE80211_MESHCONF_NULL,
- .conf_syncid = IEEE80211_MESHCONF_NULL,
- .conf_authid = IEEE80211_MESHCONF_NULL,
+ .conf_ccid = IEEE80211_MESHCONF_CCSIG,
+ .conf_syncid = { 0, 0, 0, 0 }, /* XXX */
+ .conf_authid = { 0x80, 0, 0, 0 }, /* XXX */
.conf_form = 0, /* XXX */
.conf_cap = 1, /* XXX */
};
Modified: projects/mesh11s/sys/net80211/ieee80211_mesh.h
==============================================================================
--- projects/mesh11s/sys/net80211/ieee80211_mesh.h Tue Apr 28 11:10:33 2009 (r191621)
+++ projects/mesh11s/sys/net80211/ieee80211_mesh.h Tue Apr 28 11:30:18 2009 (r191622)
@@ -39,33 +39,40 @@ struct ieee80211_meshconf_ie {
uint8_t conf_ie; /* IEEE80211_ELEMID_MESHCONF */
uint8_t conf_len;
uint8_t conf_ver;
- uint32_t conf_pselid; /* Active Path Sel. Proto. ID */
- uint32_t conf_pmetid; /* APS Metric Identifier */
- uint32_t conf_ccid; /* Congestion Control Mode ID */
- uint32_t conf_syncid; /* Sync. Protocol ID */
- uint32_t conf_authid; /* Auth. Protocol ID */
+ uint8_t conf_pselid[4]; /* Active Path Sel. Proto. ID */
+ uint8_t conf_pmetid[4]; /* APS Metric Identifier */
+ uint8_t conf_ccid[4]; /* Congestion Control Mode ID */
+ uint8_t conf_syncid[4]; /* Sync. Protocol ID */
+ uint8_t conf_authid[4]; /* Auth. Protocol ID */
uint8_t conf_form; /* Formation Information */
uint8_t conf_cap;
} __packed;
#define IEEE80211_MESHCONF_VERSION 1
-#define IEEE80211_MESHCONF_NULL_OUI 0x000fac /* Null Protocol */
-#define IEEE80211_MESHCONF_NULL_VALUE 255
-#define IEEE80211_MESHCONF_NULL (IEEE80211_MESHCONF_NULL_OUI << 8 | IEEE80211_MESHCONF_NULL_VALUE)
-#define IEEE80211_MESHCONF_HWMP_OUI 0x000fac
+/* Null Protocol */
+#define IEEE80211_MESHCONF_NULL_OUI 0x00, 0x0f, 0xac
+#define IEEE80211_MESHCONF_NULL_VALUE 0xff
+#define IEEE80211_MESHCONF_NULL { IEEE80211_MESHCONF_NULL_OUI, IEEE80211_MESHCONF_NULL_VALUE }
+/* Hybrid Wireless Mesh Protocol */
+#define IEEE80211_MESHCONF_HWMP_OUI 0x00, 0x0f, 0xac
#define IEEE80211_MESHCONF_HWMP_VALUE 0xff /* XXX Linux */
-#define IEEE80211_MESHCONF_HWMP (IEEE80211_MESHCONF_HWMP_OUI << 8 | IEEE80211_MESHCONF_HWMP_VALUE)
-#define IEEE80211_MESHCONF_AIRTIME_OUI 0x000fac
+#define IEEE80211_MESHCONF_HWMP { IEEE80211_MESHCONF_HWMP_OUI, IEEE80211_MESHCONF_HWMP_VALUE }
+/* Airtime Link Metric */
+#define IEEE80211_MESHCONF_AIRTIME_OUI 0x00, 0x0f, 0xac
#define IEEE80211_MESHCONF_AIRTIME_VALUE 0xff /* XXX Linux */
-#define IEEE80211_MESHCONF_AIRTIME (IEEE80211_MESHCONF_AIRTIME_OUI << 8 | IEEE80211_MESHCONF_AIRTIME_VALUE)
-#define IEEE80211_MESHCONF_CCSIG_OUI 0x000fac
+#define IEEE80211_MESHCONF_AIRTIME { IEEE80211_MESHCONF_AIRTIME_OUI, IEEE80211_MESHCONF_AIRTIME_VALUE }
+/* Congestion Control Signaling */
+#define IEEE80211_MESHCONF_CCSIG_OUI 0x00, 0x0f, 0xac
#define IEEE80211_MESHCONF_CCSIG_VALUE 0xff /* XXX Linux */
-#define IEEE80211_MESHCONF_NEIGHOFF_OUI 0x000fac /* Neighbour offset */
-#define IEEE80211_MESHCONF_NEIGHOFF_VALUE 0
-#define IEEE80211_MESHCONF_NEIGHOFF (IEEE80211_MESHCONF_NEIGHOFF_OUI << 8 | IEEE80211_MESHCONF_NEIGHOFF_VALUE)
-#define IEEE80211_MESHCONF_SAE_OUI 0x000fac
-#define IEEE80211_MESHCONF_SAE_VALUE 1
-#define IEEE80211_MESHCONF_SAE (IEEE80211_MESHCONF_SAE_OUI << 8 | IEEE80211_MESHCONF_SAE_VALUE)
+#define IEEE80211_MESHCONF_CCSIG { IEEE80211_MESHCONF_CCSIG_OUI, IEEE80211_MESHCONF_CCSIG_VALUE }
+/* Neighbour Offset */
+#define IEEE80211_MESHCONF_NEIGHOFF_OUI 0x00, 0x0f, 0xac
+#define IEEE80211_MESHCONF_NEIGHOFF_VALUE 0x00
+#define IEEE80211_MESHCONF_NEIGHOFF { IEEE80211_MESHCONF_NEIGHOFF_OUI, IEEE80211_MESHCONF_NEIGHOFF_VALUE }
+/* Simultaneous Authenticaction of Equals */
+#define IEEE80211_MESHCONF_SAE_OUI 0x00, 0x0f, 0xac
+#define IEEE80211_MESHCONF_SAE_VALUE 0x01
+#define IEEE80211_MESHCONF_SAE { IEEE80211_MESHCONF_SAE_OUI, IEEE80211_MESHCONF_SAE_VALUE }
#define IEEE80211_MESHCONF_FORM_MP (1 << 1) /* connected to portal */
#define IEEE80211_MESHCONF_FORM_NEIGH (1 << 4) /* no of neighbours */
/* XXX ... */
More information about the svn-src-projects
mailing list