Commit 9e82abdd0c0341b880f510fc8b19464410912069

Authored by Ben Greear
Committed by Greg Kroah-Hartman
1 parent 199a81acf2

mac80211: Clear beacon_int in ieee80211_do_stop

commit 5c21e8100dfd57c806e833ae905e26efbb87840f upstream.

This fixes stale beacon-int values that would keep a netdev
from going up.

To reproduce:

Create two VAP on one radio.
vap1 has beacon-int 100, start it.
vap2 has beacon-int 240, start it (and it will fail
  because beacon-int mismatch).
reconfigure vap2 to have beacon-int 100 and start it.
  It will fail because the stale beacon-int 240 will be used
  in the ifup path and hostapd never gets a chance to set the
  new beacon interval.

Cc: stable@vger.kernel.org
Signed-off-by: Ben Greear <greearb@candelatech.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

Showing 1 changed file with 2 additions and 0 deletions Side-by-side Diff

net/mac80211/iface.c
... ... @@ -1032,6 +1032,8 @@
1032 1032 if (local->open_count == 0)
1033 1033 ieee80211_clear_tx_pending(local);
1034 1034  
  1035 + sdata->vif.bss_conf.beacon_int = 0;
  1036 +
1035 1037 /*
1036 1038 * If the interface goes down while suspended, presumably because
1037 1039 * the device was unplugged and that happens before our resume,