1. 23 Apr, 2012 5 commits
    • Larry Finger's avatar
      rtlwifi: Fix oops on unload · 44eb65cf
      Larry Finger authored
      Under some circumstances, a PCI-based driver reports the following OOPs:
      
      Mar 19 08:14:35 kvothe kernel: [ 6584.626011] Oops: 0000 [#1] SMP
      --snip--
      Mar 19 08:14:35 kvothe kernel: [ 6584.626011] Pid: 19627, comm: rmmod
      Not tainted 3.2.9-2.fc16.x86_64 #1 LENOVO 05962RU/05962RU
      Mar 19 08:14:35 kvothe kernel: [ 6584.626011] RIP:
      0010:[<ffffffffa0418d39>]  [<ffffffffa0418d39>]
      rtl92ce_get_desc+0x19/0xd0 [rtl8192ce]
      --snip--
      Mar 19 08:14:35 kvothe kernel: [ 6584.626011] Process rmmod (pid:
      19627, threadinfo ffff880050262000, task ffff8801156d5cc0)
      Mar 19 08:14:35 kvothe kernel: [ 6584.626011] Stack:
      Mar 19 08:14:35 kvothe kernel: [ 6584.626011]  0000000000000002
      ffff8801176c2540 ffff880050263ca8 ffffffffa03348e7
      Mar 19 08:14:35 kvothe kernel: [ 6584.626011]  0000000000000282
      0000000180150014 ffff880050263fd8 ffff8801176c2810
      Mar 19 08:14:35 kvothe kernel: [ 6584.626011]  ffff880050263bc8
      ffffffff810550e2 00000000000002c0 ffff8801176c0d40
      Mar 19 08:14:35 kvothe kernel: [ 6584.626011] Call Trace:
      Mar 19 08:14:35 kvothe kernel: [ 6584.626011]  [<ffffffffa03348e7>]
      _rtl_pci_rx_interrupt+0x187/0x650 [rtlwifi]
      --snip--
      Mar 19 08:14:35 kvothe kernel: [ 6584.626011] Code: ff 09 d0 89 07 48
      83 c4 08 5b 5d c3 66 0f 1f 44 00 00 55 48 89 e5 53 48 83 ec 08 66 66
      66 66 90 40 84 f6 89 d3 74 13 84 d2 75 57 <8b> 07 48 83 c4 08 5b 5d c1
      e8 1f c3 0f 1f 00 84 d2 74 ed 80 fa
      Mar 19 08:14:35 kvothe kernel: [ 6584.626011] RIP
      [<ffffffffa0418d39>] rtl92ce_get_desc+0x19/0xd0 [rtl8192ce]
      Mar 19 08:14:35 kvothe kernel: [ 6584.626011]  RSP <ffff880050263b58>
      Mar 19 08:14:35 kvothe kernel: [ 6584.626011] CR2: 00000000000006e0
      Mar 19 08:14:35 kvothe kernel: [ 6584.646491] ---[ end trace
      8636c766dcfbe0e6 ]---
      
      This oops is due to interrupts not being disabled in this particular path.
      Reported-by: default avatarDave Airlie <airlied@gmail.com>
      Tested-by: default avatarDave Airlie <airlied@gmail.com>
      Signed-off-by: default avatarLarry Finger <Larry.Finger@lwfinger.net>
      Cc: Stable <stable@vger.kernel.org>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      44eb65cf
    • Stanislav Yakovlev's avatar
      ipw2200: Fix race condition in the command completion acknowledge · dd447319
      Stanislav Yakovlev authored
      Driver incorrectly validates command completion: instead of waiting
      for a command to be acknowledged it continues execution.  Most of the
      time driver gets acknowledge of the command completion in a tasklet
      before it executes the next one. But sometimes it sends the next
      command before it gets acknowledge for the previous one. In such a
      case one of the following error messages appear in the log:
      
      Failed to send SYSTEM_CONFIG: Already sending a command.
      Failed to send ASSOCIATE: Already sending a command.
      Failed to send TX_POWER: Already sending a command.
      
      After that you need to reload the driver to get it working again.
      
      This bug occurs during roaming (reported by Sam Varshavchik)
      https://bugzilla.redhat.com/show_bug.cgi?id=738508
      and machine booting (reported by Tom Gundersen and Mads Kiilerich)
      https://bugs.archlinux.org/task/28097
      https://bugzilla.redhat.com/show_bug.cgi?id=802106
      
      This patch doesn't fix the delay issue during firmware load.
      But at least device now works as usual after boot.
      
      Cc: stable@kernel.org
      Signed-off-by: default avatarStanislav Yakovlev <stas.yakovlev@gmail.com>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      dd447319
    • Stanislaw Gruszka's avatar
      iwlwifi: do not nulify ctx->vif on reset · 8db4c7e2
      Stanislaw Gruszka authored
      ctx->vif is dereferenced in different part of iwlwifi code, so do not
      nullify it.
      
      This should address at least one of the possible reasons of WARNING at
      iwlagn_mac_remove_interface, and perhaps some random crashes when
      firmware reset is performed.
      
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarStanislaw Gruszka <sgruszka@redhat.com>
      Signed-off-by: default avatarWey-Yi Guy <wey-yi.w.guy@intel.com>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      8db4c7e2
    • Gabor Juhos's avatar
      ath9k: fix tx power settings for AR9287 · 83722bd4
      Gabor Juhos authored
      The 'ath9k_hw_update_regulatory_maxpower'
      helper function has been introduced by
      commit a55f8588
      (ath9k_hw: Cleanup TX power calculation for AR9287).
      
      Updating of the max_power_level value has been moved
      into the helper function in that change, however the
      removed code from 'ath9k_hw_ar9287_set_txpower' has
      not been replaced with a call of the new helper
      function.
      
      Due to that missing call, retrieving tx power for 2x2
      and 3x3 chainmask is not handled properly. During the
      calculation of the tx power for 2x2 and 3x3 chainmasks
      the values are reduced. Those reductions must be
      compensated during retrieving.
      
      Fix this by adding the missing call of the helper
      function.
      Signed-off-by: default avatarGabor Juhos <juhosg@openwrt.org>
      Acked-by: default avatarSujith Manoharan <c_manoha@qca.qualcomm.com>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      83722bd4
    • Gabor Juhos's avatar
      ath9k: add an extra boolean parameter to ath9k_hw_apply_txpower · 64ea57d0
      Gabor Juhos authored
      In order to unifying regulatory limit handling
      commit ca2c68cc
      (ath9k_hw: clean up tx power handling) introduced
      a new helper function 'ath9k_hw_apply_txpower',
      and the direct calls of 'ah->eep_ops->set_txpower'
      has been replaced by a call of the helper function.
      
      This caused a change in the behaviour of the
      'ath9k_hw_set_txpowerlimit' function. The purpose
      of that function is to calculate and store the
      rate txpower table and the regulatory limit without
      touching the hardware registers. Before the commit,
      the 'test' parameter of the function was passed to
      the 'ah->eep_ops->set_txpower'. Now the calling of
      the 'set_txpower' function happens indirectly through
      'ath9k_hw_apply_txpower', so the 'test' argument of
      the 'set_txpower' is always 'false'.
      
      This patch restores the original behaviour of
      'ath9k_hw_set_txpowerlimit' by adding a new
      argument to 'ath9k_hw_apply_txpower.'
      Signed-off-by: default avatarGabor Juhos <juhosg@openwrt.org>
      Acked-by: default avatarFelix Fietkau <nbd@openwrt.org>
      Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
      64ea57d0
  2. 17 Apr, 2012 4 commits
  3. 16 Apr, 2012 1 commit
  4. 13 Apr, 2012 7 commits
  5. 11 Apr, 2012 3 commits
  6. 10 Apr, 2012 3 commits
  7. 09 Apr, 2012 7 commits
  8. 06 Apr, 2012 10 commits
    • Linus Torvalds's avatar
      Make the "word-at-a-time" helper functions more commonly usable · f68e556e
      Linus Torvalds authored
      I have a new optimized x86 "strncpy_from_user()" that will use these
      same helper functions for all the same reasons the name lookup code uses
      them.  This is preparation for that.
      
      This moves them into an architecture-specific header file.  It's
      architecture-specific for two reasons:
      
       - some of the functions are likely to want architecture-specific
         implementations.  Even if the current code happens to be "generic" in
         the sense that it should work on any little-endian machine, it's
         likely that the "multiply by a big constant and shift" implementation
         is less than optimal for an architecture that has a guaranteed fast
         bit count instruction, for example.
      
       - I expect that if architectures like sparc want to start playing
         around with this, we'll need to abstract out a few more details (in
         particular the actual unaligned accesses).  So we're likely to have
         more architecture-specific stuff if non-x86 architectures start using
         this.
      
         (and if it turns out that non-x86 architectures don't start using
         this, then having it in an architecture-specific header is still the
         right thing to do, of course)
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      f68e556e
    • Linus Torvalds's avatar
      Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net · 23f347ef
      Linus Torvalds authored
      Pull networking updates from David Miller:
      
       1) Fix inaccuracies in network driver interface documentation, from Ben
          Hutchings.
      
       2) Fix handling of negative offsets in BPF JITs, from Jan Seiffert.
      
       3) Compile warning, locking, and refcounting fixes in netfilter's
          xt_CT, from Pablo Neira Ayuso.
      
       4) phonet sendmsg needs to validate user length just like any other
          datagram protocol, fix from Sasha Levin.
      
       5) Ipv6 multicast code uses wrong loop index, from RongQing Li.
      
       6) Link handling and firmware fixes in bnx2x driver from Yaniv Rosner
          and Yuval Mintz.
      
       7) mlx4 erroneously allocates 4 pages at a time, regardless of page
          size, fix from Thadeu Lima de Souza Cascardo.
      
       8) SCTP socket option wasn't extended in a backwards compatible way,
          fix from Thomas Graf.
      
       9) Add missing address change event emissions to bonding, from Shlomo
          Pongratz.
      
      10) /proc/net/dev regressed because it uses a private offset to track
          where we are in the hash table, but this doesn't track the offset
          pullback that the seq_file code does resulting in some entries being
          missed in large dumps.
      
          Fix from Eric Dumazet.
      
      11) do_tcp_sendpage() unloads the send queue way too fast, because it
          invokes tcp_push() when it shouldn't.  Let the natural sequence
          generated by the splice paths, and the assosciated MSG_MORE
          settings, guide the tcp_push() calls.
      
          Otherwise what goes out of TCP is spaghetti and doesn't batch
          effectively into GSO/TSO clusters.
      
          From Eric Dumazet.
      
      12) Once we put a SKB into either the netlink receiver's queue or a
          socket error queue, it can be consumed and freed up, therefore we
          cannot touch it after queueing it like that.
      
          Fixes from Eric Dumazet.
      
      13) PPP has this annoying behavior in that for every transmit call it
          immediately stops the TX queue, then calls down into the next layer
          to transmit the PPP frame.
      
          But if that next layer can take it immediately, it just un-stops the
          TX queue right before returning from the transmit method.
      
          Besides being useless work, it makes several facilities unusable, in
          particular things like the equalizers.  Well behaved devices should
          only stop the TX queue when they really are full, and in PPP's case
          when it gets backlogged to the downstream device.
      
          David Woodhouse therefore fixed PPP to not stop the TX queue until
          it's downstream can't take data any more.
      
      14) IFF_UNICAST_FLT got accidently lost in some recent stmmac driver
          changes, re-add.  From Marc Kleine-Budde.
      
      15) Fix link flaps in ixgbe, from Eric W. Multanen.
      
      16) Descriptor writeback fixes in e1000e from Matthew Vick.
      
      * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (47 commits)
        net: fix a race in sock_queue_err_skb()
        netlink: fix races after skb queueing
        doc, net: Update ndo_start_xmit return type and values
        doc, net: Remove instruction to set net_device::trans_start
        doc, net: Update netdev operation names
        doc, net: Update documentation of synchronisation for TX multiqueue
        doc, net: Remove obsolete reference to dev->poll
        ethtool: Remove exception to the requirement of holding RTNL lock
        MAINTAINERS: update for Marvell Ethernet drivers
        bonding: properly unset current_arp_slave on slave link up
        phonet: Check input from user before allocating
        tcp: tcp_sendpages() should call tcp_push() once
        ipv6: fix array index in ip6_mc_add_src()
        mlx4: allocate just enough pages instead of always 4 pages
        stmmac: re-add IFF_UNICAST_FLT for dwmac1000
        bnx2x: Clear MDC/MDIO warning message
        bnx2x: Fix BCM57711+BCM84823 link issue
        bnx2x: Clear BCM84833 LED after fan failure
        bnx2x: Fix BCM84833 PHY FW version presentation
        bnx2x: Fix link issue for BCM8727 boards.
        ...
      23f347ef
    • Eric Dumazet's avatar
      net: fix a race in sock_queue_err_skb() · 110c4330
      Eric Dumazet authored
      As soon as an skb is queued into socket error queue, another thread
      can consume it, so we are not allowed to reference skb anymore, or risk
      use after free.
      Signed-off-by: default avatarEric Dumazet <eric.dumazet@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      110c4330
    • Eric Dumazet's avatar
      netlink: fix races after skb queueing · 4a7e7c2a
      Eric Dumazet authored
      As soon as an skb is queued into socket receive_queue, another thread
      can consume it, so we are not allowed to reference skb anymore, or risk
      use after free.
      Signed-off-by: default avatarEric Dumazet <eric.dumazet@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      4a7e7c2a
    • Ben Hutchings's avatar
      doc, net: Update ndo_start_xmit return type and values · e34fac1c
      Ben Hutchings authored
      Commit dc1f8bf6 ('netdev: change
      transmit to limited range type') changed the required return type and
      9a1654ba ('net: Optimize
      hard_start_xmit() return checking') changed the valid numerical
      return values.
      Signed-off-by: default avatarBen Hutchings <bhutchings@solarflare.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      e34fac1c
    • Ben Hutchings's avatar
      doc, net: Remove instruction to set net_device::trans_start · de7aca16
      Ben Hutchings authored
      Commit 08baf561 ('net:
      txq_trans_update() helper') made it unnecessary for most drivers to
      set net_device::trans_start (or netdev_queue::trans_start).
      Signed-off-by: default avatarBen Hutchings <bhutchings@solarflare.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      de7aca16
    • Ben Hutchings's avatar
      doc, net: Update netdev operation names · b3cf6545
      Ben Hutchings authored
      Commits d314774c ('netdev: network
      device operations infrastructure') and
      00829823 ('netdev: add more functions
      to netdevice ops') moved and renamed net device operation pointers.
      Signed-off-by: default avatarBen Hutchings <bhutchings@solarflare.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      b3cf6545
    • Ben Hutchings's avatar
      doc, net: Update documentation of synchronisation for TX multiqueue · 04fd3d35
      Ben Hutchings authored
      Commits e308a5d8 ('netdev: Add
      netdev->addr_list_lock protection.') and
      e8a0464c ('netdev: Allocate multiple
      queues for TX.') introduced more fine-grained locks.
      Signed-off-by: default avatarBen Hutchings <bhutchings@solarflare.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      04fd3d35
    • Ben Hutchings's avatar
      doc, net: Remove obsolete reference to dev->poll · 93b6a3ad
      Ben Hutchings authored
      Commit bea3348e ('[NET]: Make NAPI
      polling independent of struct net_device objects.') removed the
      automatic disabling of NAPI polling by dev_close(), and drivers
      must now do this themselves.
      Signed-off-by: default avatarBen Hutchings <bhutchings@solarflare.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      93b6a3ad
    • Ben Hutchings's avatar
      ethtool: Remove exception to the requirement of holding RTNL lock · b4f79e5c
      Ben Hutchings authored
      Commit e52ac339 ('net: Use device
      model to get driver name in skb_gso_segment()') removed the only
      in-tree caller of ethtool ops that doesn't hold the RTNL lock.
      Signed-off-by: default avatarBen Hutchings <bhutchings@solarflare.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      b4f79e5c