Skip to content

Commit

Permalink
mac80211: ibss should not purge clients it is not responsible for
Browse files Browse the repository at this point in the history
The IBSS merge code calls ieee80211_sta_expire() with a relatively
short expire timeout that purges other clients prematurely. The
expire function has to check that only the clients belonging to
the vif in question are purged.

Signed-off-by: Marek Lindner <lindner_marek@yahoo.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
  • Loading branch information
Marek Lindner authored and John W. Linville committed Dec 21, 2011
1 parent eca107f commit ec2b774
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions net/mac80211/sta_info.c
Original file line number Diff line number Diff line change
Expand Up @@ -946,6 +946,9 @@ void ieee80211_sta_expire(struct ieee80211_sub_if_data *sdata,

mutex_lock(&local->sta_mtx);
list_for_each_entry_safe(sta, tmp, &local->sta_list, list)
if (sdata != sta->sdata)
continue;

if (time_after(jiffies, sta->last_rx + exp_time)) {
#ifdef CONFIG_MAC80211_IBSS_DEBUG
printk(KERN_DEBUG "%s: expiring inactive STA %pM\n",
Expand Down

0 comments on commit ec2b774

Please sign in to comment.