Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 171676
b: refs/heads/master
c: 8f2fda9
h: refs/heads/master
v: v3
  • Loading branch information
Rui Paulo authored and John W. Linville committed Nov 11, 2009
1 parent 3eff2fd commit f358c35
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: a1935218da8964a033bdf68c591629741c94eeec
refs/heads/master: 8f2fda9594f083981ad54c1994863875fe680925
9 changes: 6 additions & 3 deletions trunk/net/mac80211/mesh.c
Original file line number Diff line number Diff line change
Expand Up @@ -223,6 +223,7 @@ void mesh_mgmt_ies_add(struct sk_buff *skb, struct ieee80211_sub_if_data *sdata)
struct ieee80211_supported_band *sband;
u8 *pos;
int len, i, rate;
u8 neighbors;

sband = local->hw.wiphy->bands[local->hw.conf.channel->band];
len = sband->n_bitrates;
Expand Down Expand Up @@ -271,9 +272,11 @@ void mesh_mgmt_ies_add(struct sk_buff *skb, struct ieee80211_sub_if_data *sdata)
/* Authentication Protocol identifier */
*pos++ = sdata->u.mesh.mesh_auth_id;

/* Mesh Formation Info */
memset(pos, 0x00, 1);
pos += 1;
/* Mesh Formation Info - number of neighbors */
neighbors = atomic_read(&sdata->u.mesh.mshstats.estab_plinks);
/* Number of neighbor mesh STAs or 15 whichever is smaller */
neighbors = (neighbors > 15) ? 15 : neighbors;
*pos++ = neighbors << 1;

/* Mesh capability */
sdata->u.mesh.accepting_plinks = mesh_plink_availables(sdata);
Expand Down
2 changes: 2 additions & 0 deletions trunk/net/mac80211/mesh_plink.c
Original file line number Diff line number Diff line change
Expand Up @@ -65,13 +65,15 @@ void mesh_plink_inc_estab_count(struct ieee80211_sub_if_data *sdata)
{
atomic_inc(&sdata->u.mesh.mshstats.estab_plinks);
mesh_accept_plinks_update(sdata);
ieee80211_bss_info_change_notify(sdata, BSS_CHANGED_BEACON);
}

static inline
void mesh_plink_dec_estab_count(struct ieee80211_sub_if_data *sdata)
{
atomic_dec(&sdata->u.mesh.mshstats.estab_plinks);
mesh_accept_plinks_update(sdata);
ieee80211_bss_info_change_notify(sdata, BSS_CHANGED_BEACON);
}

/**
Expand Down

0 comments on commit f358c35

Please sign in to comment.