1. 31 1月, 2009 4 次提交
  2. 30 1月, 2009 21 次提交
  3. 28 1月, 2009 5 次提交
  4. 27 1月, 2009 10 次提交
    • D
      tcp: Fix length tcp_splice_data_recv passes to skb_splice_bits. · 9fa5fdf2
      Dimitris Michailidis 提交于
      tcp_splice_data_recv has two lengths to consider: the len parameter it
      gets from tcp_read_sock, which specifies the amount of data in the skb,
      and rd_desc->count, which is the amount of data the splice caller still
      wants.  Currently it passes just the latter to skb_splice_bits, which then
      splices min(rd_desc->count, skb->len - offset) bytes.
      
      Most of the time this is fine, except when the skb contains urgent data.
      In that case len goes only up to the urgent byte and is less than
      skb->len - offset.  By ignoring len tcp_splice_data_recv may a) splice
      data tcp_read_sock told it not to, b) return to tcp_read_sock a value > len.
      
      Now, tcp_read_sock doesn't handle used > len and leaves the socket in a
      bad state (both sk_receive_queue and copied_seq are bad at that point)
      resulting in duplicated data and corruption.
      
      Fix by passing min(rd_desc->count, len) to skb_splice_bits.
      Signed-off-by: NDimitris Michailidis <dm@chelsio.com>
      Acked-by: NEric Dumazet <dada1@cosmosbay.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      9fa5fdf2
    • M
      r6040: Remove unused variable pdev from drivers/net/r6040.c · a7a41acf
      Manish Katiyar 提交于
      drivers/net/r6040.c:441: warning: unused variable 'pdev'
      Signed-off-by: NManish Katiyar <mkatiyar@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      a7a41acf
    • E
      udp: optimize bind(0) if many ports are in use · 98322f22
      Eric Dumazet 提交于
      commit 9088c560
      (udp: Improve port randomization) introduced a regression for UDP bind() syscall
      to null port (getting a random port) in case lot of ports are already in use.
      
      This is because we do about 28000 scans of very long chains (220 sockets per chain),
      with many spin_lock_bh()/spin_unlock_bh() calls.
      
      Fix this using a bitmap (64 bytes for current value of UDP_HTABLE_SIZE)
      so that we scan chains at most once.
      
      Instead of 250 ms per bind() call, we get after patch a time of 2.9 ms 
      
      Based on a report from Vitaly Mayatskikh
      Reported-by: NVitaly Mayatskikh <v.mayatskih@gmail.com>
      Signed-off-by: NEric Dumazet <dada1@cosmosbay.com>
      Tested-by: NVitaly Mayatskikh <v.mayatskih@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      98322f22
    • I
      virtio_net: use correct accessors for scatterlists · 8527bec5
      Ira W. Snyder 提交于
      Without this fix, virtio_net makes incorrect usage of scatterlists. It sets
      the end of the scatterlist chain after the first element, despite the fact
      that more entries come after it.
      
      If you try to run dma_map_sg() on one of the scatterlists given to you by
      add_buf(), you will get a null pointer oops.
      Signed-off-by: NIra W. Snyder <iws@ovro.caltech.edu>
      Signed-off-by: NRusty Russell <rusty@rustcorp.com.au>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      8527bec5
    • L
      Merge master.kernel.org:/home/rmk/linux-2.6-arm · 53760710
      Linus Torvalds 提交于
      * master.kernel.org:/home/rmk/linux-2.6-arm: (22 commits)
        [ARM] fix section-based ioremap
        [NET] am79c961a: fix spin_lock usage
        [ARM] omap: usb: thou shalt not provide empty release functions
        [ARM] omap: watchdog: allow OMAP watchdog driver on OMAP34xx platforms
        [ARM] 5369/1: omap mmc: Add new omap hsmmc controller for 2430 and 34xx, v3
        [ARM] clkdev: fix clock matching
        [ARM] 5370/1: at91: fix rm9200 watchdog
        [ARM] 5368/1: arch/arm/mach-davinci/usb.c buildfix
        [ARM] 5365/1: s3cmci: Use new include path of dma.h
        [ARM] fix StrongARM-11x0 page copy implementation
        [ARM] omap: ensure OMAP drivers pass a struct device to clk_get()
        ARM: OMAP: Fix compile for h3 MMC
        ARM: OMAP: Remove unused platform devices, v3
        ARM: OMAP: Fix ASoC by enabling writes to XCCR and RCCR McBSP registers, v3
        ARM: OMAP: Fix OSK ASoC by registering I2C board info for tlvaic23
        ARM: OMAP: remove duplicated #include's
        ARM: OMAP: Fix DMA CCR programming for request line > 63, v3
        ARM: OMAP: Fix gpio.c compile on 15xx with CONFIG_DEBUGFS
        ARM: OMAP: Fix compile for beagle
        ARM: OMAP: Fix gpio by switching to generic gpio calls, v2
        ...
      53760710
    • L
      Merge branch 'i2c-for-linus' of git://jdelvare.pck.nerim.net/jdelvare-2.6 · cfb901bf
      Linus Torvalds 提交于
      * 'i2c-for-linus' of git://jdelvare.pck.nerim.net/jdelvare-2.6:
        i2c: Warn on deprecated binding model use
        eeprom: More consistent symbol names
        eeprom: Move 93cx6 eeprom driver to /drivers/misc/eeprom
        spi: Move at25 (for SPI eeproms) to /drivers/misc/eeprom
        i2c: Move old eeprom driver to /drivers/misc/eeprom
        i2c: Move at24 to drivers/misc/eeprom
        i2c: Quilt tree has moved
        i2c: Delete many unused adapter IDs
        i2c: Delete 10 unused driver IDs
      cfb901bf
    • L
      Merge git://git.kernel.org/pub/scm/linux/kernel/git/sam/kbuild-fixes · 2034563c
      Linus Torvalds 提交于
      * git://git.kernel.org/pub/scm/linux/kernel/git/sam/kbuild-fixes:
        kbuild: fix kbuild.txt typos
        kbuild: print usage with no arguments in scripts/config
        Revert "kbuild: strip generated symbols from *.ko"
      2034563c
    • L
      Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6 · 924d26df
      Linus Torvalds 提交于
      * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6: (92 commits)
        gianfar: Revive VLAN support
        vlan: Export symbols as non GPL symbols.
        bnx2x: tx_has_work should not wait for FW
        netxen: reduce memory footprint
        netxen: fix vlan tso/checksum offload
        net: Fix linux/if_frad.h's suitability for userspace.
        net: Move config NET_NS to from net/Kconfig to init/Kconfig
        isdn: Fix missing ifdef in isdn_ppp
        networking: document "nc" in addition to "netcat" in netconsole.txt
        e1000e: workaround hw errata
        af_key: initialize xfrm encap_oa
        virtio_net: Fix MAX_PACKET_LEN to support 802.1Q VLANs
        lcs: fix compilation for !CONFIG_IP_MULTICAST
        rtl8187: Add termination packet to prevent stall
        iwlwifi: fix rs_get_rate WARN_ON()
        p54usb: fix packet loss with first generation devices
        sctp: Fix another socket race during accept/peeloff
        sctp: Properly timestamp outgoing data chunks for rtx purposes
        sctp: Correctly start rtx timer on new packet transmissions.
        sctp: Fix crc32c calculations on big-endian arhes.
        ...
      924d26df
    • L
      Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc-2.6 · 66673f13
      Linus Torvalds 提交于
      * git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc-2.6:
        sparc64: Fix DAX handling via userspace access from kernel.
        sparc64: Annotate sparc64 specific syscalls with SYSCALL_DEFINEx()
        [CVE-2009-0029] sparc: Enable syscall wrappers for 64-bit
        sparc64: Initialize FHC/CLOCK LED platform_device 'id' field correctly.
        sparc64: fix modpost failure
        sparc64: fix readout of cpu/fpu type
      66673f13
    • A
      gianfar: Revive VLAN support · cd1f55a5
      Anton Vorontsov 提交于
      commit 77ecaf2d ("gianfar: Fix VLAN
      HW feature related frame/buffer size calculation") wrongly removed
      priv->vlgrp assignment, and now priv->vlgrp is always NULL.
      
      This patch fixes the issue, plus fixes following sparse warning
      introduced by the same commit:
      gianfar.c:1406:13: warning: context imbalance in 'gfar_vlan_rx_register' - wrong count at exit
      
      gfar_vlan_rx_register() checks for "if (old_grp == grp)" and tries
      to return w/o dropping the lock.
      
      According to net/8021q/vlan.c VLAN core issues rx_register() callback:
      1. In register_vlan_dev() only on a newly created group;
      2. In unregister_vlan_dev() only if the group becomes empty.
      
      Thus the check in the gianfar driver isn't needed.
      Signed-off-by: NAnton Vorontsov <avorontsov@ru.mvista.com>
      Acked-by: NAndy Fleming <afleming@freescale.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      cd1f55a5