1. 24 6月, 2013 1 次提交
  2. 25 5月, 2013 2 次提交
  3. 24 3月, 2013 1 次提交
    • J
      cfg80211: always check for scan end on P2P device · f9f47529
      Johannes Berg 提交于
      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: NJohannes Berg <johannes.berg@intel.com>
      f9f47529
  4. 07 3月, 2013 1 次提交
    • J
      cfg80211: fix potential BSS memory leak and update · 1345ee6a
      Johannes Berg 提交于
      In the odd case that while updating information from a beacon,
      a BSS was found that is part of a hidden group, we drop the
      new information. In this case, however, we leak the IE buffer
      from the update, and erroneously update the entry's timestamp
      so it will never time out. Fix both these issues.
      
      Cc: Larry Finger <Larry.Finger@lwfinger.net>
      Signed-off-by: NJohannes Berg <johannes.berg@intel.com>
      1345ee6a
  5. 15 2月, 2013 1 次提交
  6. 13 2月, 2013 1 次提交
  7. 12 2月, 2013 4 次提交
    • J
      cfg80211: move TSF into IEs · 8cef2c9d
      Johannes Berg 提交于
      While technically the TSF isn't an IE, it can be
      necessary to distinguish between the TSF from a
      beacon and a probe response, in particular in
      order to know the next DTIM TBTT, as not all APs
      are spec compliant wrt. TSF==0 being a DTIM TBTT
      and thus the DTIM count needs to be taken into
      account as well.
      
      To allow this, move the TSF into the IE struct
      so it can be known whence it came.
      Signed-off-by: NJohannes Berg <johannes.berg@intel.com>
      8cef2c9d
    • J
      cfg80211: remove scan ies NULL check · 83c7aa1a
      Johannes Berg 提交于
      There's no way scan BSS IEs can be NULL as even
      if the allocation fails the frame is discarded.
      Remove some code checking for this and document
      that it is always non-NULL.
      Signed-off-by: NJohannes Berg <johannes.berg@intel.com>
      83c7aa1a
    • J
      cfg80211: track hidden SSID networks properly · 776b3580
      Johannes Berg 提交于
      Currently, cfg80211 will copy beacon IEs from a previously
      received hidden SSID beacon to a probe response entry, if
      that entry is created after the beacon entry. However, if
      it is the other way around, or if the beacon is updated,
      such changes aren't propagated.
      
      Fix this by tracking the relation between the probe
      response and beacon BSS structs in this case.
      
      In case drivers have private data stored in a BSS struct
      and need access to such data from a beacon entry, cfg80211
      now provides the hidden_beacon_bss pointer from the probe
      response entry to the beacon entry.
      Signed-off-by: NJohannes Berg <johannes.berg@intel.com>
      776b3580
    • J
      cfg80211: pass wiphy to cfg80211_ref_bss/put_bss · 5b112d3d
      Johannes Berg 提交于
      This prepares for using the spinlock instead of krefs
      which is needed in the next patch to track the refs
      of combined BSSes correctly.
      
      Acked-by: Bing Zhao <bzhao@marvell.com> [mwifiex]
      Signed-off-by: NJohannes Berg <johannes.berg@intel.com>
      5b112d3d
  8. 05 2月, 2013 9 次提交
  9. 31 1月, 2013 1 次提交
  10. 24 1月, 2013 1 次提交
  11. 30 11月, 2012 4 次提交
  12. 23 11月, 2012 1 次提交
    • J
      cfg80211: use DS or HT operation IEs to determine BSS channel · 0172bb75
      Johannes Berg 提交于
      Currently, mac80211 checks the DS params IE if present and
      uses it for the (primary) BSS channel, instead of the one
      that the frame was received on. This is particularly useful
      in the 2.4 GHz band since a frame is often received on one
      of the adjacent channels due to overlap.
      
      Move this code to cfg80211 so other drivers also do this.
      
      Additionally, on 5 GHz, in particular with some (possibly)
      upcoming changes in 802.11ai and duplicate transmissions
      when wider channels are used, something similar happens.
      So if present, also use the (primary) channel information
      contained in the HT operation IE.
      Signed-off-by: NJohannes Berg <johannes.berg@intel.com>
      0172bb75
  13. 18 10月, 2012 4 次提交
  14. 05 9月, 2012 1 次提交
  15. 12 7月, 2012 1 次提交
  16. 10 5月, 2012 1 次提交
    • J
      wireless: Convert compare_ether_addr to ether_addr_equal · ac422d3c
      Joe Perches 提交于
      Use the new bool function ether_addr_equal to add
      some clarity and reduce the likelihood for misuse
      of compare_ether_addr for sorting.
      
      I removed a conversion from scan.c/cmp_bss_core
      that appears to be a sorting function.
      
      Done via cocci script:
      
      $ cat compare_ether_addr.cocci
      @@
      expression a,b;
      @@
      -	!compare_ether_addr(a, b)
      +	ether_addr_equal(a, b)
      
      @@
      expression a,b;
      @@
      -	compare_ether_addr(a, b)
      +	!ether_addr_equal(a, b)
      
      @@
      expression a,b;
      @@
      -	!ether_addr_equal(a, b) == 0
      +	ether_addr_equal(a, b)
      
      @@
      expression a,b;
      @@
      -	!ether_addr_equal(a, b) != 0
      +	!ether_addr_equal(a, b)
      
      @@
      expression a,b;
      @@
      -	ether_addr_equal(a, b) == 0
      +	!ether_addr_equal(a, b)
      
      @@
      expression a,b;
      @@
      -	ether_addr_equal(a, b) != 0
      +	ether_addr_equal(a, b)
      
      @@
      expression a,b;
      @@
      -	!!ether_addr_equal(a, b)
      +	ether_addr_equal(a, b)
      Signed-off-by: NJoe Perches <joe@perches.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      ac422d3c
  17. 09 5月, 2012 1 次提交
  18. 17 4月, 2012 1 次提交
  19. 10 4月, 2012 1 次提交
  20. 14 3月, 2012 1 次提交
  21. 07 2月, 2012 1 次提交
  22. 12 11月, 2011 1 次提交
    • D
      cfg80211: merge in beacon ies of hidden bss. · dd9dfb9f
      Dmitry Tarnyagin 提交于
      The problem with PSM when a hidden SSID was used was originally
      reported by Juuso Oikarinen.
      
       - When generally scanning, the AP is getting a bss entry with
         a zero SSID.
       - When associating, a probe-req is sent to the AP with the SSID,
         and as a result a probe-response is received with the hidden
         SSID in place. As a consequence, a second bss entry is created
         for the AP, now with the real SSID.
       - After association, mac80211 executes ieee80211_recalc_ps(),
         but does not switch to powersave because the beacon-ies are missing.
      
      As result, the STA does not ever enter PSM.
      
      The patch merges in beacon ies of hidden bss from beacon to the probe
      response, creating a consistent set of ies in place.
      
      Patch is depended on "cfg80211: fix cmp_ies" made by Johannes.
      Signed-off-by: NDmitry Tarnyagin <dmitry.tarnyagin@stericsson.com>
      Signed-off-by: NJohn W. Linville <linville@tuxdriver.com>
      dd9dfb9f