1. 10 Apr, 2013 1 commit
    • Johannes Berg's avatar
      mac80211: fix cfg80211 interaction on auth/assoc request · 7b119dc0
      Johannes Berg authored
      If authentication (or association with FT) is requested by
      userspace, mac80211 currently doesn't tell cfg80211 that it
      disconnected from the AP. That leaves inconsistent state:
      cfg80211 thinks it's connected while mac80211 thinks it's
      not. Typically this won't last long, as soon as mac80211
      reports the new association to cfg80211 the old one goes
      away. If, however, the new authentication or association
      doesn't succeed, then cfg80211 will forever think the old
      one still exists and will refuse attempts to authenticate
      or associate with the AP it thinks it's connected to.
      
      Anders reported that this leads to it taking a very long
      time to reconnect to a network, or never even succeeding.
      I tested this with an AP hacked to never respond to auth
      frames, and one that works, and with just those two the
      system never recovers because one won't work and cfg80211
      thinks it's connected to the other so refuses connections
      to it.
      
      To fix this, simply make mac80211 tell cfg80211 when it is
      no longer connected to the old AP, while authenticating or
      associating to a new one.
      
      Cc: stable@vger.kernel.org
      Reported-by: default avatarAnders Kaseorg <andersk@mit.edu>
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      7b119dc0
  2. 08 Apr, 2013 1 commit
  3. 30 Mar, 2013 1 commit
    • Artem Savkov's avatar
      cfg80211: sched_scan_mtx lock in cfg80211_conn_work() · 90e0970f
      Artem Savkov authored
      Introduced in f9f47529
      ("cfg80211: always check for scan end on P2P device")
      
      cfg80211_conn_scan() which requires sched_scan_mtx to be held can be called
      from cfg80211_conn_work(). Without this we are hitting multiple warnings like
      the following:
      
      WARNING: at net/wireless/sme.c:88 cfg80211_conn_scan+0x1dc/0x3a0 [cfg80211]()
      Hardware name: 0578A21
      Modules linked in: ...
      Pid: 620, comm: kworker/3:1 Not tainted 3.9.0-rc4-next-20130328+ #326
      Call Trace:
       [<c1036992>] warn_slowpath_common+0x72/0xa0
       [<c10369e2>] warn_slowpath_null+0x22/0x30
       [<faa4b0ec>] cfg80211_conn_scan+0x1dc/0x3a0 [cfg80211]
       [<faa4b344>] cfg80211_conn_do_work+0x94/0x380 [cfg80211]
       [<faa4c3b2>] cfg80211_conn_work+0xa2/0x130 [cfg80211]
       [<c1051858>] process_one_work+0x198/0x450
      Signed-off-by: default avatarArtem Savkov <artem.savkov@gmail.com>
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      90e0970f
  4. 25 Mar, 2013 2 commits
  5. 24 Mar, 2013 2 commits
    • Ben Greear's avatar
      mac80211: Don't restart sta-timer if not associated. · 370bd005
      Ben Greear authored
      I found another crash when deleting lots of virtual stations
      in a congested environment.  I think the problem is that
      the ieee80211_mlme_notify_scan_completed could call
      ieee80211_restart_sta_timer for a stopped interface
      that was about to be deleted.
      
      With the following patch I am unable to reproduce the
      crash.
      Signed-off-by: default avatarBen Greear <greearb@candelatech.com>
      [move check, also make the same change in mesh]
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      370bd005
    • Johannes Berg's avatar
      cfg80211: always check for scan end on P2P device · f9f47529
      Johannes Berg authored
      If a P2P device wdev is removed while it has a scan, then the
      scan completion might crash later as it is already freed by
      that time. To avoid the crash always check the scan completion
      when the P2P device is being removed for some reason. If the
      driver already canceled it, don't want and free it, otherwise
      warn and leak it to avoid later crashes.
      
      In order to do this, locking needs to be changed away from the
      rdev mutex (which can't always be guaranteed). For now, use
      the sched_scan_mtx instead, I'll rename it to just scan_mtx in
      a later patch.
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      f9f47529
  6. 20 Mar, 2013 2 commits
  7. 11 Mar, 2013 1 commit
  8. 07 Mar, 2013 2 commits
  9. 06 Mar, 2013 1 commit
    • Johannes Berg's avatar
      mac80211: always synchronize_net() during station removal · 27a737ff
      Johannes Berg authored
      If there are keys left during station removal, then a
      synchronize_net() will be done (for each key, I have a
      patch to address this for 3.10), otherwise it won't be
      done at all which causes issues because the station
      could be used for TX while it's being removed from the
      driver -- that might confuse the driver.
      
      Fix this by always doing synchronize_net() if no key
      was present any more.
      
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      27a737ff
  10. 02 Mar, 2013 1 commit
  11. 01 Mar, 2013 3 commits
    • Johannes Berg's avatar
      mac80211: fix VHT MCS calculation · 24af717c
      Johannes Berg authored
      The VHT MCSes we advertise to the AP were supposed to
      be restricted to the AP, but due to a bug in the logic
      mac80211 will advertise rates to the AP that aren't
      even supported by the local device. To fix this skip
      any adjustment if the NSS isn't supported at all.
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      24af717c
    • Marco Porsch's avatar
      mac80211: fix oops on mesh PS broadcast forwarding · 7cbf9d01
      Marco Porsch authored
      Introduced with de74a1d9
      "mac80211: fix WPA with VLAN on AP side with ps-sta".
      Apparently overwrites the sdata pointer with non-valid data in
      the case of mesh.
      Fix this by checking for IFTYPE_AP_VLAN.
      Signed-off-by: default avatarMarco Porsch <marco@cozybit.com>
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      7cbf9d01
    • Johannes Berg's avatar
      nl80211: increase wiphy dump size dynamically · 645e77de
      Johannes Berg authored
      Given a device with many channels capabilities the wiphy
      information can still overflow even though its size in
      3.9 was reduced to 3.8 levels. For new userspace and
      kernel 3.10 we're going to implement a new "split dump"
      protocol that can use multiple messages per wiphy.
      
      For now though, add a workaround to be able to send more
      information to userspace. Since generic netlink doesn't
      have a way to set the minimum dump size globally, and we
      wouldn't really want to set it globally anyway, increase
      the size only when needed, as described in the comments.
      As userspace might not be prepared for large buffers, we
      can only use 4k.
      
      Also increase the size for the get_wiphy command.
      Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
      645e77de
  12. 28 Feb, 2013 1 commit
  13. 27 Feb, 2013 1 commit
  14. 26 Feb, 2013 5 commits
  15. 25 Feb, 2013 4 commits
  16. 22 Feb, 2013 3 commits
  17. 18 Feb, 2013 9 commits