1. 17 May, 2010 1 commit
    • Julia Lawall's avatar
      HID: picolcd: Eliminate use after free · aeacb6fd
      Julia Lawall authored
      The skip label frees resp, which has not been allocated at the point of
      this goto and then does a break, based on the fact that err is non-zero.
      This is replaced by a break directly.
      
      A simplified version of the semantic match that finds this problem is as
      follows: (http://coccinelle.lip6.fr/)
      
      // <smpl>
      @free@
      expression E;
      position p;
      @@
      kfree@p(E)
      
      @@
      expression free.E, subE<=free.E, E1;
      position free.p;
      @@
      
        kfree@p(E)
        ...
      (
        subE = E1
      |
      * E
      )
      // </smpl>
      Signed-off-by: default avatarJulia Lawall <julia@diku.dk>
      Signed-off-by: default avatarJiri Kosina <jkosina@suse.cz>
      aeacb6fd
  2. 03 May, 2010 2 commits
  3. 27 Apr, 2010 2 commits
  4. 26 Apr, 2010 1 commit
  5. 11 Apr, 2010 1 commit
  6. 06 Apr, 2010 7 commits
    • Linus Torvalds's avatar
      Merge branch 'upstream-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jgarzik/libata-dev · ab195c58
      Linus Torvalds authored
      * 'upstream-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jgarzik/libata-dev:
        libata: unlock HPA if device shrunk
        libata: disable NCQ on Crucial C300 SSD
        libata: don't whine on spurious IRQ
      ab195c58
    • Linus Torvalds's avatar
      Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6 · cb4361c1
      Linus Torvalds authored
      * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6: (37 commits)
        smc91c92_cs: fix the problem of "Unable to find hardware address"
        r8169: clean up my printk uglyness
        net: Hook up cxgb4 to Kconfig and Makefile
        cxgb4: Add main driver file and driver Makefile
        cxgb4: Add remaining driver headers and L2T management
        cxgb4: Add packet queues and packet DMA code
        cxgb4: Add HW and FW support code
        cxgb4: Add register, message, and FW definitions
        netlabel: Fix several rcu_dereference() calls used without RCU read locks
        bonding: fix potential deadlock in bond_uninit()
        net: check the length of the socket address passed to connect(2)
        stmmac: add documentation for the driver.
        stmmac: fix kconfig for crc32 build error
        be2net: fix bug in vlan rx path for big endian architecture
        be2net: fix flashing on big endian architectures
        be2net: fix a bug in flashing the redboot section
        bonding: bond_xmit_roundrobin() fix
        drivers/net: Add missing unlock
        net: gianfar - align BD ring size console messages
        net: gianfar - initialize per-queue statistics
        ...
      cb4361c1
    • Dan Carpenter's avatar
      proc: copy_to_user() returns unsigned · 309361e0
      Dan Carpenter authored
      copy_to_user() returns the number of bytes left to be copied.
      
      This was a typo from: d82ef020 "proc: pagemap: Hold mmap_sem during
      page walk".
      Signed-off-by: default avatarDan Carpenter <error27@gmail.com>
      Acked-by: default avatarMatt Mackall <mpm@selenic.com>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      309361e0
    • Tejun Heo's avatar
      libata: unlock HPA if device shrunk · 445d211b
      Tejun Heo authored
      Some BIOSes don't configure HPA during boot but do so while resuming.
      This causes harddrives to shrink during resume making libata detach
      and reattach them.  This can be worked around by unlocking HPA if old
      size equals native size.
      
      Add ATA_DFLAG_UNLOCK_HPA so that HPA unlocking can be controlled
      per-device and update ata_dev_revalidate() such that it sets
      ATA_DFLAG_UNLOCK_HPA and fails with -EIO when the above condition is
      detected.
      
      This patch fixes the following bug.
      
        https://bugzilla.kernel.org/show_bug.cgi?id=15396Signed-off-by: default avatarTejun Heo <tj@kernel.org>
      Reported-by: default avatarOleksandr Yermolenko <yaa.bta@gmail.com>
      Signed-off-by: default avatarJeff Garzik <jgarzik@redhat.com>
      445d211b
    • Tejun Heo's avatar
      libata: disable NCQ on Crucial C300 SSD · 68b0ddb2
      Tejun Heo authored
      Crucial said,
      
        Thank you for contacting us. We know that with our M225 line of SSDs
        you sometimes need to disable NCQ (native command queuing) to avoid
        just the type of errors you're seeing. Our recommendation for the
        M225 is to add libata.force=noncq to your Linux kernel boot options,
        under the kernel ATA library option.
      
        I have sent your feedback to the engineers working on the C300, and
        asked them to please pass it on to the firmware team. I have been
        notified that they are in the process of testing and finalizing a
        new firmware version, that you can expect to see released around the
        end of April. We’ll keep you posted as to when it will be available
        for download.
      
      So, turn off NCQ on the drive w/ the current firmware revision.
      
      Reported in the following bug.
      
        https://bugzilla.kernel.org/show_bug.cgi?id=15573Signed-off-by: default avatarTejun Heo <tj@kernel.org>
      Reported-by: lethalwp@scarlet.be
      Reported-by: default avatarLuke Macken <lmacken@redhat.com>
      Signed-off-by: default avatarJeff Garzik <jgarzik@redhat.com>
      68b0ddb2
    • Tejun Heo's avatar
      libata: don't whine on spurious IRQ · c710f785
      Tejun Heo authored
      On configurations where IRQ line is shared with a different
      controller, spurious IRQs may happen continuously.  The message was
      put there primarily for debugging anyway.  Kill it.
      Signed-off-by: default avatarTejun Heo <tj@kernel.org>
      Signed-off-by: default avatarJeff Garzik <jgarzik@redhat.com>
      c710f785
    • Nick Piggin's avatar
      Fix up possibly racy module refcounting · 5fbfb18d
      Nick Piggin authored
      Module refcounting is implemented with a per-cpu counter for speed.
      However there is a race when tallying the counter where a reference may
      be taken by one CPU and released by another.  Reference count summation
      may then see the decrement without having seen the previous increment,
      leading to lower than expected count.  A module which never has its
      actual reference drop below 1 may return a reference count of 0 due to
      this race.
      
      Module removal generally runs under stop_machine, which prevents this
      race causing bugs due to removal of in-use modules.  However there are
      other real bugs in module.c code and driver code (module_refcount is
      exported) where the callers do not run under stop_machine.
      
      Fix this by maintaining running per-cpu counters for the number of
      module refcount increments and the number of refcount decrements.  The
      increments are tallied after the decrements, so any decrement seen will
      always have its corresponding increment counted.  The final refcount is
      the difference of the total increments and decrements, preventing a
      low-refcount from being returned.
      Signed-off-by: default avatarNick Piggin <npiggin@suse.de>
      Acked-by: default avatarRusty Russell <rusty@rustcorp.com.au>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      5fbfb18d
  7. 05 Apr, 2010 22 commits
  8. 04 Apr, 2010 4 commits