1. 15 11月, 2011 17 次提交
  2. 22 9月, 2011 2 次提交
    • S
      iwlegacy: do not use interruptible waits · 65d0f19e
      Stanislaw Gruszka 提交于
      iwlegacy version of fix:
      
      commit effd4d9a
      Author: Johannes Berg <johannes.berg@intel.com>
      Date:   Thu Sep 15 11:46:52 2011 -0700
      
          iwlagn: do not use interruptible waits
      
          Since the dawn of its time, iwlwifi has used
          interruptible waits to wait for synchronous
          commands and firmware loading.
      
          This leads to "interesting" bugs, because it
          can't actually handle the interruptions; for
          example when a command sending is interrupted
          it will assume the command completed fully,
          and then leave it pending, which leads to all
          kinds of trouble when the command finishes
          later.
      
          Since there's no easy way to gracefully deal
          with interruptions, fix the driver to not use
          interruptible waits.
      
          This at least fixes the error
          iwlagn 0000:02:00.0: Error: Response NULL in  'REPLY_SCAN_ABORT_CMD'
      
          I have seen in P2P testing, but it is likely
          that there are other errors caused by this.
      
      Cc: stable@kernel.org # 2.6.39+
      Signed-off-by: NStanislaw Gruszka <sgruszka@redhat.com>
      Signed-off-by: NJohn W. Linville <linville@tuxdriver.com>
      65d0f19e
    • S
      iwlegacy: fix command queue timeout · 2e2a41d6
      Stanislaw Gruszka 提交于
      iwlegacy version of fix:
      
      commit 282cdb32
      Author: Johannes Berg <johannes.berg@intel.com>
      Date:   Mon Sep 12 12:09:10 2011 -0700
      
          iwlagn: fix command queue timeout
      
          If the command queue is constantly busy,
          which can happen in P2P, the hangcheck
          timer will frequently find a command in
          it and will eventually reset the device
          because nothing sets the timestamp for
          this queue when commands are processed.
      
          Fix this by setting the timestamp when
          a command completes.
      
      iwlegacy does not support P2P, but this patch fix possible
      unneeded hardware resets, hence is needed.
      
      Cc: stable@kernel.org  # 2.6.39+
      Signed-off-by: NStanislaw Gruszka <sgruszka@redhat.com>
      Signed-off-by: NJohn W. Linville <linville@tuxdriver.com>
      2e2a41d6
  3. 30 4月, 2011 1 次提交
    • S
      iwlegacy: fix enqueue hcmd race conditions · 81e63263
      Stanislaw Gruszka 提交于
      We mark command as huge by using meta->flags from other (non huge) command,
      but flags can be possibly overridden, when non huge command is enqueued,
      what can lead to:
      
      WARNING: at lib/dma-debug.c:696 dma_debug_device_change+0x1a3/0x1f0()
      DMA-API: device driver has pending DMA allocations while released from device [count=1]
      
      To fix introduce additional CMD_MAPPED to mark command as mapped and
      serialize iwl_enqueue_hcmd() with iwl_tx_cmd_complete() using
      hcmd_lock. Serialization will also fix possible race conditions,
      because q->read_ptr, q->write_ptr are modified/used in parallel.
      
      Do not change callback, I did (and fixed) that mistake in iwlagn.
      Signed-off-by: NStanislaw Gruszka <sgruszka@redhat.com>
      Signed-off-by: NJohn W. Linville <linville@tuxdriver.com>
      81e63263
  4. 01 3月, 2011 1 次提交
  5. 22 2月, 2011 3 次提交
  6. 07 12月, 2010 1 次提交
  7. 16 11月, 2010 2 次提交
  8. 08 10月, 2010 1 次提交
  9. 18 9月, 2010 1 次提交
  10. 27 8月, 2010 1 次提交
  11. 25 8月, 2010 1 次提交
  12. 06 6月, 2010 1 次提交
  13. 05 6月, 2010 1 次提交
  14. 14 5月, 2010 1 次提交
  15. 10 4月, 2010 2 次提交
  16. 03 4月, 2010 3 次提交
    • F
      iwlwifi: remove trailing space in messages · 91dd6c27
      Frans Pop 提交于
      Includes minor improvements in debugging messages in iwl-4965.c,
      function iwl4965_is_temp_calib_needed().
      Signed-off-by: NFrans Pop <elendil@planet.nl>
      Cc: Zhu Yi <yi.zhu@intel.com>
      Cc: Reinette Chatre <reinette.chatre@intel.com>
      Cc: Intel Linux Wireless <ilw@linux.intel.com>
      Signed-off-by: NReinette Chatre <reinette.chatre@intel.com>
      91dd6c27
    • Z
      iwlwifi: avoid Tx queue memory allocation in interface down · de0f60ea
      Zhu Yi 提交于
      We used to free all the Tx queues memory when interface is brought
      down and reallocate them again in interface up. This requires
      order-4 allocation for txq->cmd[]. In situations like s2ram, this
      usually leads to allocation failure in the memory subsystem. The
      patch fixed this problem by allocating the Tx queues memory only at
      the first time. Later iwl_down/iwl_up only initialize but don't
      free and reallocate them. The memory is freed at the device removal
      time. BTW, we have already done this for the Rx queue.
      
      This fixed bug https://bugzilla.kernel.org/show_bug.cgi?id=15551Signed-off-by: NZhu Yi <yi.zhu@intel.com>
      Acked-by: NWey-Yi Guy <wey-yi.w.guy@intel.com>
      Signed-off-by: NReinette Chatre <reinette.chatre@intel.com>
      de0f60ea
    • Z
      iwlwifi: fix DMA allocation warnings · dd487449
      Zhu Yi 提交于
      Below warning is triggered sometimes at module removal time when
      CONFIG_DMA_API_DEBUG is enabled. This should be caused by we didn't
      unmap pending commands (enqueued, but no complete notification
      received) for the Tx command queue.
      
      [ 1583.107469] ------------[ cut here ]------------
      [ 1583.107539] WARNING: at lib/dma-debug.c:688
      dma_debug_device_change+0x13c/0x180()
      [ 1583.107617] Hardware name: ...
      [ 1583.107664] pci 0000:04:00.0: DMA-API: device driver has pending DMA
      allocations while released from device [count=1]
      [ 1583.107713] Modules linked in: ...
      [ 1583.111661] Pid: 16970, comm: modprobe Tainted: G        W
      2.6.34-rc1-wl #33
      [ 1583.111727] Call Trace:
      [ 1583.111779]  [<c02a281c>] ? dma_debug_device_change+0x13c/0x180
      [ 1583.111833]  [<c02a281c>] ? dma_debug_device_change+0x13c/0x180
      [ 1583.111908]  [<c0138e11>] warn_slowpath_common+0x71/0xd0
      [ 1583.111963]  [<c02a281c>] ? dma_debug_device_change+0x13c/0x180
      [ 1583.112016]  [<c0138ebb>] warn_slowpath_fmt+0x2b/0x30
      [ 1583.112086]  [<c02a281c>] dma_debug_device_change+0x13c/0x180
      [ 1583.112142]  [<c03e6c33>] notifier_call_chain+0x53/0x90
      [ 1583.112198]  [<c03e1ebe>] ? down_read+0x6e/0x90
      [ 1583.112271]  [<c015b229>] __blocking_notifier_call_chain+0x49/0x70
      [ 1583.112326]  [<c015b26f>] blocking_notifier_call_chain+0x1f/0x30
      [ 1583.112380]  [<c031931c>] __device_release_driver+0x8c/0xa0
      [ 1583.112451]  [<c03193bf>] driver_detach+0x8f/0xa0
      [ 1583.112538]  [<c0318382>] bus_remove_driver+0x82/0x100
      [ 1583.112595]  [<c0319ad9>] driver_unregister+0x49/0x80
      [ 1583.112671]  [<c024feb2>] ? sysfs_remove_file+0x12/0x20
      [ 1583.112727]  [<c02aa292>] pci_unregister_driver+0x32/0x80
      [ 1583.112791]  [<fc13a3c1>] iwl_exit+0x12/0x19 [iwlagn]
      [ 1583.112848]  [<c017940a>] sys_delete_module+0x15a/0x210
      [ 1583.112870]  [<c015a5db>] ? up_read+0x1b/0x30
      [ 1583.112893]  [<c029600c>] ? trace_hardirqs_off_thunk+0xc/0x10
      [ 1583.112924]  [<c0295ffc>] ? trace_hardirqs_on_thunk+0xc/0x10
      [ 1583.112947]  [<c03e6a1f>] ? do_page_fault+0x1ff/0x3c0
      [ 1583.112978]  [<c03e36f6>] ? restore_all_notrace+0x0/0x18
      [ 1583.113002]  [<c016aa70>] ? trace_hardirqs_on_caller+0x20/0x190
      [ 1583.113025]  [<c0102d58>] sysenter_do_call+0x12/0x38
      [ 1583.113054] ---[ end trace fc23e059cc4c2ced ]---
      Signed-off-by: NZhu Yi <yi.zhu@intel.com>
      Signed-off-by: NReinette Chatre <reinette.chatre@intel.com>
      dd487449
  17. 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