1. 07 6月, 2011 1 次提交
  2. 17 5月, 2011 1 次提交
    • J
      mac80211: sparse RCU annotations · 40b275b6
      Johannes Berg 提交于
      This adds sparse RCU annotations to most of
      mac80211, only the mesh code remains to be
      done.
      
      Due the the previous patches, the annotations
      are pretty simple. The only thing that this
      actually changes is removing the RCU usage of
      key->sta in debugfs since this pointer isn't
      actually an RCU-managed pointer (it only has
      a single assignment done before the key even
      goes live). As that is otherwise harmless, I
      decided to make it part of this patch.
      Signed-off-by: NJohannes Berg <johannes.berg@intel.com>
      Signed-off-by: NJohn W. Linville <linville@tuxdriver.com>
      40b275b6
  3. 13 5月, 2011 1 次提交
  4. 05 5月, 2011 1 次提交
    • M
      mac80211: Fix a warning due to skipping tailroom reservation for IV · eaef6a93
      Mohammed Shafi Shajakhan 提交于
      The devices that require IV generation in software need tailroom
      reservation  for ICVs used in TKIP or WEP encryptions.
      Currently, decision to skip the tailroom reservation in the tx
      path was taken only on whether driver wants MMIC to be generated
      in software or not. Following patch appends IV generation check for
      such decisions and fixes the following warning.
      
      WARNING: at net/mac80211/wep.c:101 ieee80211_wep_add_iv+0x56/0xf3()
      Hardware name: 64756D6
      Modules linked in: ath9k ath9k_common ath9k_hw
      Pid: 0, comm: swapper Tainted: G        W   2.6.39-rc5-wl
       Call Trace:
      [<c102fd29>] warn_slowpath_common+0x65/0x7a
      [<c1465c4e>] ? ieee80211_wep_add_iv+0x56/0xf3
      [<c102fd4d>] warn_slowpath_null+0xf/0x13
      [<c1465c4e>] ieee80211_wep_add_iv+0x56/0xf3
      [<c1466007>] ieee80211_crypto_wep_encrypt+0x63/0x88
      [<c1478bf3>] ieee80211_tx_h_encrypt+0x2f/0x63
      [<c1478cba>] invoke_tx_handlers+0x93/0xe1
      [<c1478eda>] ieee80211_tx+0x4b/0x6d
      [<c147907c>] ieee80211_xmit+0x180/0x188
      [<c147779d>] ? ieee80211_skb_resize+0x95/0xd9
      [<c1479edf>] ieee80211_subif_start_xmit+0x64f/0x668
      [<c13956fc>] dev_hard_start_xmit+0x368/0x48c
      [<c13a8bd6>] sch_direct_xmit+0x4d/0x101
      [<c1395ae1>] dev_queue_xmit+0x2c1/0x43f
      [<c13a74a2>] ? eth_header+0x1e/0x90
      [<c13a7400>] ? eth_type_trans+0x91/0xc2
      [<c13a7484>] ? eth_rebuild_header+0x53/0x53
      [<c139f079>] neigh_resolve_output+0x223/0x27e
      [<c13c6b23>] ip_finish_output2+0x1d4/0x1fe
      [<c13c6bc6>] ip_finish_output+0x79/0x7d
      [<c13c6cbe>] T.1075+0x43/0x48
      [<c13c6e6e>] ip_output+0x75/0x7b
      [<c13c4970>] dst_output+0xc/0xe
      [<c13c62c9>] ip_local_out+0x17/0x1a
      [<c13c67bb>] ip_queue_xmit+0x2aa/0x2f8
      [<c138b742>] ? sk_setup_caps+0x21/0x92
      [<c13d95ea>] ? __tcp_v4_send_check+0x7e/0xb7
      [<c13d5d2e>] tcp_transmit_skb+0x6a1/0x6d7
      [<c13d533b>] ? tcp_established_options+0x20/0x8b
      [<c13d6f28>] tcp_retransmit_skb+0x43a/0x527
      [<c13d8d6d>] tcp_retransmit_timer+0x32e/0x45d
      [<c13d8f23>] tcp_write_timer+0x87/0x16c
      [<c103a030>] run_timer_softirq+0x156/0x1f9
      [<c13d8e9c>] ? tcp_retransmit_timer+0x45d/0x45d
      [<c1034d65>] __do_softirq+0x97/0x14a
      [<c1034cce>] ? irq_enter+0x4d/0x4d
      
      Cc: Yogesh Powar <yogeshp@marvell.com>
      Reported-by: NFabio Rossi <rossi.f@inwind.it>
      Tested-by: NFabio Rossi <rossi.f@inwind.it>
      Signed-off-by: NMohammed Shafi Shajakhan <mshajakhan@atheros.com>
      Signed-off-by: NJohn W. Linville <linville@tuxdriver.com>
      eaef6a93
  5. 29 4月, 2011 1 次提交
  6. 29 3月, 2011 2 次提交
  7. 05 1月, 2011 2 次提交
  8. 14 12月, 2010 1 次提交
  9. 23 11月, 2010 1 次提交
    • H
      mac80211: Disable hw crypto for GTKs on AP VLAN interfaces · 18890d4b
      Helmut Schaa 提交于
      When using AP VLAN interfaces, each VLAN interface should be in its own
      broadcast domain. Hostapd achieves this by assigning different GTKs to
      different AP VLAN interfaces.
      
      However, mac80211 drivers are not aware of AP VLAN interfaces and as
      such mac80211 sends the GTK to the driver in the context of the base AP
      mode interface. This causes problems when multiple AP VLAN interfaces
      are used since the driver will use the same key slot for the different
      GTKs (there's no way for the driver to distinguish the different GTKs
      from different AP VLAN interfaces). Thus, only the clients associated
      to one AP VLAN interface (the one that was created last) can actually
      use broadcast traffic.
      
      Fix this by not programming any GTKs for AP VLAN interfaces into the hw
      but fall back to using software crypto. The GTK for the underlying AP
      interface is still sent to the driver.
      
      That means, broadcast traffic to stations associated to an AP VLAN
      interface is encrypted in software whereas broadcast traffic to
      stations associated to the non-VLAN AP interface is encrypted in
      hardware.
      
      Cc: Johannes Berg <johannes@sipsolutions.net>
      Signed-off-by: NHelmut Schaa <helmut.schaa@googlemail.com>
      Signed-off-by: NJohn W. Linville <linville@tuxdriver.com>
      18890d4b
  10. 07 10月, 2010 1 次提交
  11. 17 9月, 2010 1 次提交
  12. 28 8月, 2010 1 次提交
  13. 26 8月, 2010 1 次提交
  14. 17 8月, 2010 3 次提交
  15. 28 7月, 2010 1 次提交
    • J
      mac80211: Fix key freeing to handle unlinked keys · 32162a4d
      Jouni Malinen 提交于
      Key locking simplification removed key->sdata != NULL verification from
      ieee80211_key_free(). While that is fine for most use cases, there is one
      path where this function can be called with an unlinked key (i.e.,
      key->sdata == NULL && key->local == NULL). This results in a NULL pointer
      dereference with the current implementation. This is known to happen at
      least with FT protocol when wpa_supplicant tries to configure the key
      before association.
      
      Avoid the issue by passing in the local pointer to
      ieee80211_key_free(). In addition, do not clear the key from hw_accel
      or debugfs if it has not yet been added. At least the hw_accel one could
      trigger another NULL pointer dereference.
      Signed-off-by: NJouni Malinen <j@w1.fi>
      Reviewed-by: NJohannes Berg <johannes@sipsolutions.net>
      Signed-off-by: NJohn W. Linville <linville@tuxdriver.com>
      32162a4d
  16. 16 6月, 2010 1 次提交
  17. 04 6月, 2010 1 次提交
  18. 25 5月, 2010 1 次提交
  19. 24 5月, 2010 1 次提交
    • L
      Revert "ath9k: Group Key fix for VAPs" · a69eee49
      Linus Torvalds 提交于
      This reverts commit 03ceedea, since it
      breaks resume from suspend-to-ram on Rafael's Acer Ferrari One.
      NetworkManager thinks everything is ok, but it can't connect to the AP
      to get an IP address after the resume.
      
      In fact, it even breaks resume for non-ath9k chipsets: reverting it also
      fixes Rafael's Toshiba Protege R500 with the iwlagn driver.  As Johannes
      says:
      
        "Indeed, this patch needs to be reverted. That mac80211 change is wrong
         and completely unnecessary."
      Reported-and-requested-by: NRafael J. Wysocki <rjw@sisk.pl>
      Acked-by: NJohannes Berg <johannes@sipsolutions.net>
      Cc: Daniel Yingqiang Ma <yma.cool@gmail.com>
      Cc: John W. Linville <linville@tuxdriver.com>
      Cc: David Miller <davem@davemloft.net>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      a69eee49
  20. 20 4月, 2010 1 次提交
    • D
      ath9k: Group Key fix for VAPs · 03ceedea
      Daniel Yingqiang Ma 提交于
      When I set up multiple VAPs with ath9k, I encountered an issue that
      the traffic may be lost after a while.
      
      The detailed phenomenon is
      1. After a while the clients connected to one of these VAPs will get
      into a state that no broadcast/multicast packets can be transfered
      successfully while the unicast packets can be transfered normally.
      2. Minutes latter the unitcast packets transfer will fail as well,
      because the ARP entry is expired and it can't be freshed due to the
      broadcast trouble.
      
      It's caused by the group key overwritten and someone discussed this
      issue in ath9k-devel maillist before, but haven't work out a fix yet.
      
      I referred the method in madwifi, and made a patch for ath9k.
      The method is to set the high bit of the sender(AP)'s address, and
      associated that mac and the group key. It requires the hardware
      supports multicast frame key search. It seems true for AR9160.
      
      Not sure whether it's the correct way to fix this issue. But it seems
      to work in my test. The patch is attached, feel free to revise it.
      Signed-off-by: NDaniel Yingqiang ma <yma.cool@gmail.com>
      Signed-off-by: NJohn W. Linville <linville@tuxdriver.com>
      03ceedea
  21. 30 3月, 2010 1 次提交
    • T
      include cleanup: Update gfp.h and slab.h includes to prepare for breaking... · 5a0e3ad6
      Tejun Heo 提交于
      include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h
      
      percpu.h is included by sched.h and module.h and thus ends up being
      included when building most .c files.  percpu.h includes slab.h which
      in turn includes gfp.h making everything defined by the two files
      universally available and complicating inclusion dependencies.
      
      percpu.h -> slab.h dependency is about to be removed.  Prepare for
      this change by updating users of gfp and slab facilities include those
      headers directly instead of assuming availability.  As this conversion
      needs to touch large number of source files, the following script is
      used as the basis of conversion.
      
        http://userweb.kernel.org/~tj/misc/slabh-sweep.py
      
      The script does the followings.
      
      * Scan files for gfp and slab usages and update includes such that
        only the necessary includes are there.  ie. if only gfp is used,
        gfp.h, if slab is used, slab.h.
      
      * When the script inserts a new include, it looks at the include
        blocks and try to put the new include such that its order conforms
        to its surrounding.  It's put in the include block which contains
        core kernel includes, in the same order that the rest are ordered -
        alphabetical, Christmas tree, rev-Xmas-tree or at the end if there
        doesn't seem to be any matching order.
      
      * If the script can't find a place to put a new include (mostly
        because the file doesn't have fitting include block), it prints out
        an error message indicating which .h file needs to be added to the
        file.
      
      The conversion was done in the following steps.
      
      1. The initial automatic conversion of all .c files updated slightly
         over 4000 files, deleting around 700 includes and adding ~480 gfp.h
         and ~3000 slab.h inclusions.  The script emitted errors for ~400
         files.
      
      2. Each error was manually checked.  Some didn't need the inclusion,
         some needed manual addition while adding it to implementation .h or
         embedding .c file was more appropriate for others.  This step added
         inclusions to around 150 files.
      
      3. The script was run again and the output was compared to the edits
         from #2 to make sure no file was left behind.
      
      4. Several build tests were done and a couple of problems were fixed.
         e.g. lib/decompress_*.c used malloc/free() wrappers around slab
         APIs requiring slab.h to be added manually.
      
      5. The script was run on all .h files but without automatically
         editing them as sprinkling gfp.h and slab.h inclusions around .h
         files could easily lead to inclusion dependency hell.  Most gfp.h
         inclusion directives were ignored as stuff from gfp.h was usually
         wildly available and often used in preprocessor macros.  Each
         slab.h inclusion directive was examined and added manually as
         necessary.
      
      6. percpu.h was updated not to include slab.h.
      
      7. Build test were done on the following configurations and failures
         were fixed.  CONFIG_GCOV_KERNEL was turned off for all tests (as my
         distributed build env didn't work with gcov compiles) and a few
         more options had to be turned off depending on archs to make things
         build (like ipr on powerpc/64 which failed due to missing writeq).
      
         * x86 and x86_64 UP and SMP allmodconfig and a custom test config.
         * powerpc and powerpc64 SMP allmodconfig
         * sparc and sparc64 SMP allmodconfig
         * ia64 SMP allmodconfig
         * s390 SMP allmodconfig
         * alpha SMP allmodconfig
         * um on x86_64 SMP allmodconfig
      
      8. percpu.h modifications were reverted so that it could be applied as
         a separate patch and serve as bisection point.
      
      Given the fact that I had only a couple of failures from tests on step
      6, I'm fairly confident about the coverage of this conversion patch.
      If there is a breakage, it's likely to be something in one of the arch
      headers which should be easily discoverable easily on most builds of
      the specific arch.
      Signed-off-by: NTejun Heo <tj@kernel.org>
      Guess-its-ok-by: NChristoph Lameter <cl@linux-foundation.org>
      Cc: Ingo Molnar <mingo@redhat.com>
      Cc: Lee Schermerhorn <Lee.Schermerhorn@hp.com>
      5a0e3ad6
  22. 29 12月, 2009 1 次提交
  23. 22 12月, 2009 2 次提交
  24. 18 8月, 2009 1 次提交
  25. 11 7月, 2009 1 次提交
  26. 21 5月, 2009 1 次提交
  27. 14 5月, 2009 1 次提交
    • J
      nl80211: Add RSC configuration for new keys · faa8fdc8
      Jouni Malinen 提交于
      When setting a key with NL80211_CMD_NEW_KEY, we should allow the key
      sequence number (RSC) to be set in order to allow replay protection to
      work correctly for group keys. This patch documents this use for
      nl80211 and adds the couple of missing pieces in nl80211/cfg80211 and
      mac80211 to support this. In addition, WEXT SIOCSIWENCODEEXT compat
      processing in cfg80211 is extended to handle the RSC (this was already
      specified in WEXT, but just not implemented in cfg80211/mac80211).
      Signed-off-by: NJouni Malinen <jouni.malinen@atheros.com>
      Signed-off-by: NJohn W. Linville <linville@tuxdriver.com>
      faa8fdc8
  28. 07 5月, 2009 1 次提交
  29. 28 2月, 2009 1 次提交
    • J
      mac80211: split IBSS/managed code · 46900298
      Johannes Berg 提交于
      This patch splits out the ibss code and data from managed (station) mode.
      The reason to do this is to better separate the state machines, and have
      the code be contained better so it gets easier to determine what exactly
      a given change will affect, that in turn makes it easier to understand.
      
      This is quite some churn, especially because I split sdata->u.sta into
      sdata->u.mgd and sdata->u.ibss, but I think it's easier to maintain that
      way. I've also shuffled around some code -- null function sending is only
      applicable to managed interfaces so put that into that file, some other
      functions are needed from various places so put them into util, and also
      rearranged the prototypes in ieee80211_i.h accordingly.
      Signed-off-by: NJohannes Berg <johannes@sipsolutions.net>
      Signed-off-by: NJohn W. Linville <linville@tuxdriver.com>
      46900298
  30. 30 1月, 2009 2 次提交
  31. 28 10月, 2008 1 次提交
  32. 07 10月, 2008 1 次提交
  33. 16 9月, 2008 2 次提交