1. 11 6月, 2012 2 次提交
  2. 10 6月, 2012 5 次提交
  3. 09 6月, 2012 3 次提交
    • D
      tcp: Get rid of inetpeer special cases. · 4670fd81
      David S. Miller 提交于
      The get_peer method TCP uses is full of special cases that make no
      sense accommodating, and it also gets in the way of doing more
      reasonable things here.
      
      First of all, if the socket doesn't have a usable cached route, there
      is no sense in trying to optimize timewait recycling.
      
      Likewise for the case where we have IP options, such as SRR enabled,
      that make the IP header destination address (and thus the destination
      address of the route key) differ from that of the connection's
      destination address.
      
      Just return a NULL peer in these cases, and thus we're also able to
      get rid of the clumsy inetpeer release logic.
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      4670fd81
    • D
      inet: Create and use rt{,6}_get_peer_create(). · fbfe95a4
      David S. Miller 提交于
      There's a lot of places that open-code rt{,6}_get_peer() only because
      they want to set 'create' to one.  So add an rt{,6}_get_peer_create()
      for their sake.
      
      There were also a few spots open-coding plain rt{,6}_get_peer() and
      those are transformed here as well.
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      fbfe95a4
    • G
      inetpeer: add parameter net for inet_getpeer_v4,v6 · 54db0cc2
      Gao feng 提交于
      add struct net as a parameter of inet_getpeer_v[4,6],
      use net to replace &init_net.
      
      and modify some places to provide net for inet_getpeer_v[4,6]
      Signed-off-by: NGao feng <gaofeng@cn.fujitsu.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      54db0cc2
  4. 04 6月, 2012 2 次提交
  5. 02 6月, 2012 1 次提交
    • E
      tcp: reflect SYN queue_mapping into SYNACK packets · fff32699
      Eric Dumazet 提交于
      While testing how linux behaves on SYNFLOOD attack on multiqueue device
      (ixgbe), I found that SYNACK messages were dropped at Qdisc level
      because we send them all on a single queue.
      
      Obvious choice is to reflect incoming SYN packet @queue_mapping to
      SYNACK packet.
      
      Under stress, my machine could only send 25.000 SYNACK per second (for
      200.000 incoming SYN per second). NIC : ixgbe with 16 rx/tx queues.
      
      After patch, not a single SYNACK is dropped.
      Signed-off-by: NEric Dumazet <edumazet@google.com>
      Cc: Hans Schillstrom <hans.schillstrom@ericsson.com>
      Cc: Jesper Dangaard Brouer <brouer@redhat.com>
      Cc: Neal Cardwell <ncardwell@google.com>
      Cc: Tom Herbert <therbert@google.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      fff32699
  6. 27 5月, 2012 2 次提交
    • G
      ipv6: fix incorrect ipsec fragment · 0c183379
      Gao feng 提交于
      Since commit ad0081e4
      "ipv6: Fragment locally generated tunnel-mode IPSec6 packets as needed"
      the fragment of packets is incorrect.
      because tunnel mode needs IPsec headers and trailer for all fragments,
      while on transport mode it is sufficient to add the headers to the
      first fragment and the trailer to the last.
      
      so modify mtu and maxfraglen base on ipsec mode and if fragment is first
      or last.
      
      with my test,it work well(every fragment's size is the mtu)
      and does not trigger slow fragment path.
      
      Changes from v1:
      	though optimization, mtu_prev and maxfraglen_prev can be delete.
      	replace xfrm mode codes with dst_entry's new frag DST_XFRM_TUNNEL.
      	add fuction ip6_append_data_mtu to make codes clearer.
      Signed-off-by: NGao feng <gaofeng@cn.fujitsu.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      0c183379
    • B
      xfrm: take net hdr len into account for esp payload size calculation · 91657eaf
      Benjamin Poirier 提交于
      Corrects the function that determines the esp payload size. The calculations
      done in esp{4,6}_get_mtu() lead to overlength frames in transport mode for
      certain mtu values and suboptimal frames for others.
      
      According to what is done, mainly in esp{,6}_output() and tcp_mtu_to_mss(),
      net_header_len must be taken into account before doing the alignment
      calculation.
      Signed-off-by: NBenjamin Poirier <bpoirier@suse.de>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      91657eaf
  7. 21 5月, 2012 1 次提交
    • E
      ipv6/exthdrs: strict Pad1 and PadN check · 9b905fe6
      Eldad Zack 提交于
      The following tightens the padding check from commit
      c1412fce :
      
      * Take into account combinations of consecutive Pad1 and PadN.
      
      * Catch the corner case of when only padding is present in the
        header, when the extention header length is 0 (i.e., 8 bytes).
        In this case, the header would have exactly 6 bytes of padding:
      
      +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
      :  Next Header  : Hdr Ext Len=0 :                               :
      +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+                               +
      :                        Padding (Pad1 or PadN)                 :
      +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
      Signed-off-by: NEldad Zack <eldad@fogrefinery.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      9b905fe6
  8. 20 5月, 2012 3 次提交
  9. 19 5月, 2012 4 次提交
  10. 18 5月, 2012 4 次提交
  11. 17 5月, 2012 1 次提交
  12. 16 5月, 2012 5 次提交
  13. 12 5月, 2012 1 次提交
    • E
      net/ipv6/af_inet6.c: checkpatch cleanup · 647c0c70
      Eldad Zack 提交于
      af_inet6.c:80: ERROR: do not initialise statics to 0 or NULL
      af_inet6.c:259: ERROR: spaces required around that '=' (ctx:VxV)
      af_inet6.c:394: WARNING: EXPORT_SYMBOL(foo); should immediately follow its function/variable
      af_inet6.c:412: WARNING: EXPORT_SYMBOL(foo); should immediately follow its function/variable
      af_inet6.c:422: ERROR: do not use assignment in if condition
      af_inet6.c:425: ERROR: do not use assignment in if condition
      af_inet6.c:433: ERROR: do not use assignment in if condition
      af_inet6.c:437: WARNING: EXPORT_SYMBOL(foo); should immediately follow its function/variable
      af_inet6.c:446: ERROR: spaces required around that '=' (ctx:VxV)
      af_inet6.c:478: WARNING: EXPORT_SYMBOL(foo); should immediately follow its function/variable
      af_inet6.c:485: ERROR: that open brace { should be on the previous line
      af_inet6.c:485: ERROR: space required before the open parenthesis '('
      af_inet6.c:513: WARNING: EXPORT_SYMBOL(foo); should immediately follow its function/variable
      af_inet6.c:629: WARNING: EXPORT_SYMBOL(foo); should immediately follow its function/variable
      af_inet6.c:647: WARNING: EXPORT_SYMBOL(foo); should immediately follow its function/variable
      af_inet6.c:687: WARNING: EXPORT_SYMBOL(foo); should immediately follow its function/variable
      af_inet6.c:709: WARNING: EXPORT_SYMBOL(foo); should immediately follow its function/variable
      af_inet6.c:1073: ERROR: space required before the open parenthesis '('
      Signed-off-by: NEldad Zack <eldad@fogrefinery.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      647c0c70
  14. 11 5月, 2012 1 次提交
    • A
      6lowpan: IPv6 link local address · 06a4c1c5
      alex.bluesman.smirnov@gmail.com 提交于
      According to the RFC4944 (Transmission of IPv6 Packets over
      IEEE 802.15.4 Networks), chapter 7:
      
      The IPv6 link-local address [RFC4291] for an IEEE 802.15.4 interface
      is formed by appending the Interface Identifier, as defined above, to
      the prefix FE80::/64.
      
        10 bits            54 bits                  64 bits
      +----------+-----------------------+----------------------------+
      |1111111010|         (zeros)       |    Interface Identifier    |
      +----------+-----------------------+----------------------------+
      
      This patch adds IPv6 address generation support for the 6lowpan
      interfaces.
      Signed-off-by: NAlexander Smirnov <alex.bluesman.smirnov@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      06a4c1c5
  15. 09 5月, 2012 2 次提交
  16. 05 5月, 2012 1 次提交
    • E
      tcp: be more strict before accepting ECN negociation · bd14b1b2
      Eric Dumazet 提交于
      It appears some networks play bad games with the two bits reserved for
      ECN. This can trigger false congestion notifications and very slow
      transferts.
      
      Since RFC 3168 (6.1.1) forbids SYN packets to carry CT bits, we can
      disable TCP ECN negociation if it happens we receive mangled CT bits in
      the SYN packet.
      Signed-off-by: NEric Dumazet <edumazet@google.com>
      Cc: Perry Lorier <perryl@google.com>
      Cc: Matt Mathis <mattmathis@google.com>
      Cc: Yuchung Cheng <ycheng@google.com>
      Cc: Neal Cardwell <ncardwell@google.com>
      Cc: Wilmer van der Gaast <wilmer@google.com>
      Cc: Ankur Jain <jankur@google.com>
      Cc: Tom Herbert <therbert@google.com>
      Cc: Dave Täht <dave.taht@bufferbloat.net>
      Acked-by: NNeal Cardwell <ncardwell@google.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      bd14b1b2
  17. 01 5月, 2012 1 次提交
  18. 29 4月, 2012 1 次提交