DragonFly commits List (threaded) for 2009-07
DragonFly BSD
DragonFly commits List (threaded) for 2009-07
[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]

DragonFly- master sys/kern uipc_socket.c uipc_socket2.c uipc_usrreq.c sys/netinet tcp.h tcp_input.c tcp_output.c tcp_subr.c tcp_usrreq.c tcp_var.h sys/sys socketvar.h

From: Peter Avalos <pavalos@xxxxxxxxxxxxxxxxxxxxxxx>
Date: Sun, 26 Jul 2009 14:55:38 -0700 (PDT)

commit 5b0b9fa51337cb0f3a9c78c8f74fbe4be19d719e
Author: Peter Avalos <pavalos@theshell.com>
Date:   Sun Jul 19 15:50:00 2009 -1000

    Implement autosizing TCP socket buffers.
    Normally the socket buffers are static (either derived from global
    defaults or set with setsockopt) and do not adapt to real network
    conditions. Two things happen: a) your socket buffers are too small
    and you can't reach the full potential of the network between both
    hosts; b) your socket buffers are too big and you waste a lot of
    kernel memory for data just sitting around.
    With automatic TCP send and receive socket buffers we can start with a
    small buffer and quickly grow it in parallel with the TCP congestion
    window to match real network conditions.
    New sysctls are:
      net.inet.tcp.sendbuf_auto=1 (enabled)
      net.inet.tcp.sendbuf_inc=8192 (8K, step size)
      net.inet.tcp.sendbuf_max=16777216 (16M, growth limit)
      net.inet.tcp.recvbuf_auto=1 (enabled)
      net.inet.tcp.recvbuf_inc=16384 (16K, step size)
      net.inet.tcp.recvbuf_max=16777216 (16M, growth limit)
    Additionally, add limiters and sanity checks for TCP MSS (maximum segment
    size) resource exhaustion attacks.
    Obtained-from: FreeBSD

Summary of changes:
 sys/kern/uipc_socket.c   |    6 ++
 sys/kern/uipc_socket2.c  |    8 ++-
 sys/kern/uipc_usrreq.c   |    2 +-
 sys/netinet/tcp.h        |   19 ++++++
 sys/netinet/tcp_input.c  |  145 +++++++++++++++++++++++++++++++++++++++++++++-
 sys/netinet/tcp_output.c |   69 +++++++++++++++++++++-
 sys/netinet/tcp_subr.c   |   24 ++++++++
 sys/netinet/tcp_usrreq.c |    5 +-
 sys/netinet/tcp_var.h    |   11 ++++
 sys/sys/socketvar.h      |    1 +
 10 files changed, 281 insertions(+), 9 deletions(-)


DragonFly BSD source repository

[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]