diff options
author | rpaulo <rpaulo@FreeBSD.org> | 2010-01-12 22:22:27 +0000 |
---|---|---|
committer | rpaulo <rpaulo@FreeBSD.org> | 2010-01-12 22:22:27 +0000 |
commit | cf2c03a0f9961b5c072df009fd9a1bed000a7d06 (patch) | |
tree | 21c842a07d7776a751c66bc9a8c3da699791a6bc /sys/net80211 | |
parent | 197dc264ae5cd82f3d8857f7df3fc372afc9e758 (diff) | |
download | FreeBSD-src-cf2c03a0f9961b5c072df009fd9a1bed000a7d06.zip FreeBSD-src-cf2c03a0f9961b5c072df009fd9a1bed000a7d06.tar.gz |
Update mesh code to to D4.0.
Diffstat (limited to 'sys/net80211')
-rw-r--r-- | sys/net80211/ieee80211_mesh.c | 8 | ||||
-rw-r--r-- | sys/net80211/ieee80211_mesh.h | 5 |
2 files changed, 8 insertions, 5 deletions
diff --git a/sys/net80211/ieee80211_mesh.c b/sys/net80211/ieee80211_mesh.c index d662269..4f3dc05 100644 --- a/sys/net80211/ieee80211_mesh.c +++ b/sys/net80211/ieee80211_mesh.c @@ -2381,6 +2381,7 @@ uint8_t * ieee80211_add_meshconf(uint8_t *frm, struct ieee80211vap *vap) { const struct ieee80211_mesh_state *ms = vap->iv_mesh; + uint16_t caps; KASSERT(vap->iv_opmode == IEEE80211_M_MBSS, ("not a MBSS vap")); @@ -2396,11 +2397,12 @@ ieee80211_add_meshconf(uint8_t *frm, struct ieee80211vap *vap) if (ms->ms_flags & IEEE80211_MESHFLAGS_PORTAL) *frm |= IEEE80211_MESHCONF_FORM_MP; frm += 1; - *frm = 0; + caps = 0; if (ms->ms_flags & IEEE80211_MESHFLAGS_AP) - *frm |= IEEE80211_MESHCONF_CAP_AP; + caps |= IEEE80211_MESHCONF_CAP_AP; if (ms->ms_flags & IEEE80211_MESHFLAGS_FWD) - *frm |= IEEE80211_MESHCONF_CAP_FWRD; + caps |= IEEE80211_MESHCONF_CAP_FWRD; + ADDSHORT(frm, caps); frm += 1; return frm; } diff --git a/sys/net80211/ieee80211_mesh.h b/sys/net80211/ieee80211_mesh.h index de9b5c2..ad1b02a 100644 --- a/sys/net80211/ieee80211_mesh.h +++ b/sys/net80211/ieee80211_mesh.h @@ -49,7 +49,7 @@ struct ieee80211_meshconf_ie { uint8_t conf_syncid; /* Sync. Protocol ID */ uint8_t conf_authid; /* Auth. Protocol ID */ uint8_t conf_form; /* Formation Information */ - uint8_t conf_cap; + uint16_t conf_cap; } __packed; /* Hybrid Wireless Mesh Protocol */ @@ -72,7 +72,8 @@ struct ieee80211_meshconf_ie { #define IEEE80211_MESHCONF_CAP_FWRD 0x08 /* forwarding enabled */ #define IEEE80211_MESHCONF_CAP_BTR 0x10 /* Beacon Timing Report Enab */ #define IEEE80211_MESHCONF_CAP_TBTTA 0x20 /* TBTT Adj. Enabled */ -#define IEEE80211_MESHCONF_CAP_PSL 0x40 /* Power Save Level */ +#define IEEE80211_MESHCONF_CAP_TBTT 0x40 /* TBTT Adjusting */ +#define IEEE80211_MESHCONF_CAP_PSL 0x80 /* Power Save Level */ /* Mesh Identifier */ struct ieee80211_meshid_ie { |