diff options
author | monthadar <monthadar@FreeBSD.org> | 2012-05-01 15:56:26 +0000 |
---|---|---|
committer | monthadar <monthadar@FreeBSD.org> | 2012-05-01 15:56:26 +0000 |
commit | 66eb02c1dc5e68076bf50a497792f81f047e74ea (patch) | |
tree | 7789c09019e4a96470216c276b33223cdf9db176 /sys/net80211/ieee80211_mesh.h | |
parent | 661f0aa0b474eeb0e2188d7c75ce16dbe34a0229 (diff) | |
download | FreeBSD-src-66eb02c1dc5e68076bf50a497792f81f047e74ea.zip FreeBSD-src-66eb02c1dc5e68076bf50a497792f81f047e74ea.tar.gz |
Mesh forwarding with proxy support.
* Modified HWMP PREP/PREQ to contain a proxy entry and also changed PREP
frame processing according to amendment as following:
o Fixed PREP to always update/create if acceptance criteria is meet;
o PREQ processing to reply if request is for a proxy entry that is
proxied by us;
o Removed hwmp_discover call from PREQ, because sending a PREP will
build the forward path, and by receving and accepting a PREQ we
have already built the reverse path (non-proactive code);
* Disabled code for pro-active in PREP for now (will make a separate patch for
pro-active HWMP routing later)
* Added proxy information for a Mesh route, mesh gate to use and proxy seqno;
* Modified ieee80211_encap according to amendment;
* Introduced Mesh control address extension enum and removed unused struct,
also rename some structure element names.
* Modified mesh_input and added mesh_recv_* that should verify and process mesh
data frames according to 9.32 Mesh forwarding framework in amendment;
* Modified mesh_decap accordingly to changes done in mesh control AE struct;
Approved by: adrian
Diffstat (limited to 'sys/net80211/ieee80211_mesh.h')
-rw-r--r-- | sys/net80211/ieee80211_mesh.h | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/sys/net80211/ieee80211_mesh.h b/sys/net80211/ieee80211_mesh.h index 2d2631d..f28356e 100644 --- a/sys/net80211/ieee80211_mesh.h +++ b/sys/net80211/ieee80211_mesh.h @@ -390,19 +390,18 @@ struct ieee80211_meshcntl_ae10 { uint8_t mc_flags; /* Address Extension 10 */ uint8_t mc_ttl; /* TTL */ uint8_t mc_seq[4]; /* Sequence No. */ - uint8_t mc_addr4[IEEE80211_ADDR_LEN]; - uint8_t mc_addr5[IEEE80211_ADDR_LEN]; -} __packed; - -struct ieee80211_meshcntl_ae11 { - uint8_t mc_flags; /* Address Extension 11 */ - uint8_t mc_ttl; /* TTL */ - uint8_t mc_seq[4]; /* Sequence No. */ - uint8_t mc_addr4[IEEE80211_ADDR_LEN]; uint8_t mc_addr5[IEEE80211_ADDR_LEN]; uint8_t mc_addr6[IEEE80211_ADDR_LEN]; } __packed; +#define IEEE80211_MESH_AE_MASK 0x03 +enum { + IEEE80211_MESH_AE_00 = 0, /* MC has no AE subfield */ + IEEE80211_MESH_AE_01 = 1, /* MC contain addr4 */ + IEEE80211_MESH_AE_10 = 2, /* MC contain addr5 & addr6 */ + IEEE80211_MESH_AE_11 = 3, /* RESERVED */ +}; + #ifdef _KERNEL MALLOC_DECLARE(M_80211_MESH_PREQ); MALLOC_DECLARE(M_80211_MESH_PREP); @@ -423,6 +422,7 @@ struct ieee80211_mesh_route { struct mtx rt_lock; /* fine grained route lock */ int rt_updtime; /* last update time */ uint8_t rt_dest[IEEE80211_ADDR_LEN]; + uint8_t rt_mesh_gate[IEEE80211_ADDR_LEN]; /* meshDA */ uint8_t rt_nexthop[IEEE80211_ADDR_LEN]; uint32_t rt_metric; /* path metric */ uint16_t rt_nhops; /* number of hops */ @@ -431,6 +431,7 @@ struct ieee80211_mesh_route { #define IEEE80211_MESHRT_FLAGS_PROXY 0x02 /* proxy entry */ uint32_t rt_lifetime; /* route timeout */ uint32_t rt_lastmseq; /* last seq# seen dest */ + uint32_t rt_ext_seq; /* proxy seq number */ void *rt_priv; /* private data */ }; #define IEEE80211_MESH_ROUTE_PRIV(rt, cast) ((cast *)rt->rt_priv) |