1. 06 May, 2014 31 commits
  2. 05 May, 2014 9 commits
    • David Miller's avatar
      slab: Fix off by one in object max number tests. · 30321c7b
      David Miller authored
      If freelist_idx_t is a byte, SLAB_OBJ_MAX_NUM should be 255 not 256, and
      likewise if freelist_idx_t is a short, then it should be 65535 not
      This was leading to all kinds of random crashes on sparc64 where
      PAGE_SIZE is 8192.  One problem shown was that if spinlock debugging was
      enabled, we'd get deadlocks in copy_pte_range() or do_wp_page() with the
      same cpu already holding a lock it shouldn't hold, or the lock belonging
      to a completely unrelated process.
      Fixes: a41adfaa ("slab: introduce byte sized index for the freelist of a slab")
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
    • Joonsoo Kim's avatar
      slab: fix the type of the index on freelist index accessor · 7cc68973
      Joonsoo Kim authored
      Commit a41adfaa ("slab: introduce byte sized index for the freelist
      of a slab") changes the size of freelist index and also changes
      prototype of accessor function to freelist index.  And there was a
      The mistake is that although it changes the size of freelist index
      correctly, it changes the size of the index of freelist index
      incorrectly.  With patch, freelist index can be 1 byte or 2 bytes, that
      means that num of object on on a slab can be more than 255.  So we need
      more than 1 byte for the index to find the index of free object on
      freelist.  But, above patch makes this index type 1 byte, so slab which
      have more than 255 objects cannot work properly and in consequence of
      it, the system cannot boot.
      This issue was reported by Steven King on m68knommu which would use
      2 bytes freelist index:
      To fix is easy.  To change the type of the index of freelist index on
      accessor functions is enough to fix this bug.  Although 2 bytes is
      enough, I use 4 bytes since it have no bad effect and make things more
      easier.  This fix was suggested and tested by Steven in his original
      Signed-off-by: default avatarJoonsoo Kim <iamjoonsoo.kim@lge.com>
      Reported-and-acked-by: default avatarSteven King <sfking@fdwdc.com>
      Acked-by: default avatarChristoph Lameter <cl@linux.com>
      Tested-by: default avatarJames Hogan <james.hogan@imgtec.com>
      Tested-by: default avatarDavid Miller <davem@davemloft.net>
      Cc: Pekka Enberg <penberg@kernel.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
    • Linus Torvalds's avatar
      Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net · 2080cee4
      Linus Torvalds authored
      Pull networking fixes from David Miller:
       1) e1000e computes header length incorrectly wrt vlans, fix from Vlad
       2) ns_capable() check in sock_diag netlink code, from Andrew
       3) Fix invalid queue pairs handling in virtio_net, from Amos Kong.
       4) Checksum offloading busted in sxgbe driver due to incorrect
          descriptor layout, fix from Byungho An.
       5) Fix build failure with SMC_DEBUG set to 2 or larger, from Zi Shen
       6) Fix uninitialized A and X registers in BPF interpreter, from Alexei
       7) Fix arch dependencies of candence driver.
       8) Fix netlink capabilities checking tree-wide, from Eric W Biederman.
       9) Don't dump IFLA_VF_PORTS if netlink request didn't ask for it in
          IFLA_EXT_MASK, from David Gibson.
      10) IPV6 FIB dump restart doesn't handle table changes that happen
          meanwhile, causing the code to loop forever or emit dups, fix from
          Kumar Sandararajan.
      11) Memory leak on VF removal in bnx2x, from Yuval Mintz.
      12) Bug fixes for new Altera TSE driver from Vince Bridgers.
      13) Fix route lookup key in SCTP, from Xugeng Zhang.
      14) Use BH blocking spinlocks in SLIP, as per a similar fix to CAN/SLCAN
          driver.  From Oliver Hartkopp.
      15) TCP doesn't bump retransmit counters in some code paths, fix from
          Eric Dumazet.
      16) Clamp delayed_ack in tcp_cubic to prevent theoretical divides by
          zero.  Fix from Liu Yu.
      17) Fix locking imbalance in error paths of HHF packet scheduler, from
          John Fastabend.
      18) Properly reference the transport module when vsock_core_init() runs,
          from Andy King.
      19) Fix buffer overflow in cdc_ncm driver, from Bjørn Mork.
      20) IP_ECN_decapsulate() doesn't see a correct SKB network header in
          ip_tunnel_rcv(), fix from Ying Cai.
      * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (132 commits)
        net: macb: Fix race between HW and driver
        net: macb: Remove 'unlikely' optimization
        net: macb: Re-enable RX interrupt only when RX is done
        net: macb: Clear interrupt flags
        net: macb: Pass same size to DMA_UNMAP as used for DMA_MAP
        ip_tunnel: Set network header properly for IP_ECN_decapsulate()
        e1000e: Restrict MDIO Slow Mode workaround to relevant parts
        e1000e: Fix issue with link flap on 82579
        e1000e: Expand workaround for 10Mb HD throughput bug
        e1000e: Workaround for dropped packets in Gig/100 speeds on 82579
        net/mlx4_core: Don't issue PCIe speed/width checks for VFs
        net/mlx4_core: Load the Eth driver first
        net/mlx4_core: Fix slave id computation for single port VF
        net/mlx4_core: Adjust port number in qp_attach wrapper when detaching
        net: cdc_ncm: fix buffer overflow
        Altera TSE: ALTERA_TSE should depend on HAS_DMA
        vsock: Make transport the proto owner
        net: sched: lock imbalance in hhf qdisc
        net: mvmdio: Check for a valid interrupt instead of an error
        net phy: Check for aneg completion before setting state to PHY_RUNNING
    • Linus Torvalds's avatar
      Merge tag 'usb-3.15-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb · 783e9e8e
      Linus Torvalds authored
      Pull USB fixes from Greg KH:
       "Here are some small fixes and device ids for 3.15-rc4.
        All have been in linux-next just fine"
      * tag 'usb-3.15-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb:
        USB: Nokia 5300 should be treated as unusual dev
        USB: Nokia 305 should be treated as unusual dev
        fsl-usb: do not test for PHY_CLK_VALID bit on controller version 1.6
        usb: storage: shuttle_usbat: fix discs being detected twice
        usb: qcserial: add a number of Dell devices
        USB: OHCI: fix problem with global suspend on ATI controllers
        usb: gadget: at91-udc: fix irq and iomem resource retrieval
        usb: phy: fsm: change "|" to "||" for condition OTG_STATE_A_WAIT_BCON at statemachine
        usb: phy: fsm: update OTG HNP state transition
    • Linus Torvalds's avatar
      Merge tag 'tty-3.15-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty · df862f62
      Linus Torvalds authored
      Pull tty/serial fixes from Greg KH:
       "Here are some tty and serial driver fixes for things reported
      * tag 'tty-3.15-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty:
        tty: Fix lockless tty buffer race
        Revert "tty: Fix race condition between __tty_buffer_request_room and flush_to_ldisc"
        drivers/tty/hvc: don't free hvc_console_setup after init
        n_tty: Fix n_tty_write crash when echoing in raw mode
        tty: serial: 8250_core.c Bug fix for Exar chips.
    • Linus Torvalds's avatar
      Merge tag 'staging-3.15-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging · a1e74464
      Linus Torvalds authored
      Pull staging / iio fixes from Greg KH:
       "Here are some small IIO driver fixes for 3.15-rc4 that resolve some
        reported issues"
      * tag 'staging-3.15-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging:
        iio: adc: Nothing in ADC should be a bool CONFIG
        iio: exynos_adc: use indio_dev->dev structure to handle child nodes
        iio:imu:mpu6050: Fixed segfault in Invensens MPU driver due to null dereference
        staging:iio:ad2s1200 fix missing parenthesis in a for statment.
    • Linus Torvalds's avatar
      Merge tag 'xtensa-next-20140503' of git://github.com/czankel/xtensa-linux · 03787ff6
      Linus Torvalds authored
      Pull Xtensa fixes from Chris Zankel:
       - Fixes allmodconfig, allnoconfig builds
       - Adds highmem support
       - Enables build-time exception table sorting.
      * tag 'xtensa-next-20140503' of git://github.com/czankel/xtensa-linux:
        xtensa: ISS: don't depend on CONFIG_TTY
        xtensa: xt2000: drop redundant sysmem initialization
        xtensa: add support for KC705
        xtensa: xtfpga: introduce SoC I/O bus
        xtensa: add HIGHMEM support
        xtensa: optimize local_flush_tlb_kernel_range
        xtensa: dump sysmem from the bootmem_init
        xtensa: handle memmap kernel option
        xtensa: keep sysmem banks ordered in mem_reserve
        xtensa: keep sysmem banks ordered in add_sysmem_bank
        xtensa: split bootparam and kernel meminfo
        xtensa: enable sorting extable at build time
        xtensa: export __{invalidate,flush}_dcache_range
        xtensa: Export __invalidate_icache_range
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client · 5575eeb7
      Linus Torvalds authored
      Pull Ceph fixes from Sage Weil:
       "First, there is a critical fix for the new primary-affinity function
        that went into -rc1.
        The second batch of patches from Zheng fix a range of problems with
        directory fragmentation, readdir, and a few odds and ends for cephfs"
      * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client:
        ceph: reserve caps for file layout/lock MDS requests
        ceph: avoid releasing caps that are being used
        ceph: clear directory's completeness when creating file
        libceph: fix non-default values check in apply_primary_affinity()
        ceph: use fpos_cmp() to compare dentry positions
        ceph: check directory's completeness before emitting directory entry
    • Soren Brinkmann's avatar
      net: macb: Fix race between HW and driver · c8ea5a22
      Soren Brinkmann authored
      Under "heavy" RX load, the driver cannot handle the descriptors fast
      enough. In detail, when a descriptor is consumed, its used flag is
      cleared and once the RX budget is consumed all descriptors with a
      cleared used flag are prepared to receive more data. Under load though,
      the HW may constantly receive more data and use those descriptors with a
      cleared used flag before they are actually prepared for next usage.
      The head and tail pointers into the RX-ring should always be valid and
      we can omit clearing and checking of the used flag.
      Signed-off-by: default avatarSoren Brinkmann <soren.brinkmann@xilinx.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>