From: Eric Dumazet <eric.dumazet@gmail.com>
To: "H.K. Jerry Chu" <hkchu@google.com>
Cc: davem@davemloft.net, ycheng@google.com, edumazet@google.com,
ncardwell@google.com, sivasankar@cs.ucsd.edu,
therbert@google.com, netdev@vger.kernel.org
Subject: Re: [PATCH 1/3] tcp: TCP Fast Open Server - header & support functions
Date: Fri, 31 Aug 2012 07:21:07 -0700 [thread overview]
Message-ID: <1346422867.2591.47.camel@edumazet-glaptop> (raw)
In-Reply-To: <1346369948-1722-2-git-send-email-hkchu@google.com>
On Thu, 2012-08-30 at 16:39 -0700, H.K. Jerry Chu wrote:
> From: Jerry Chu <hkchu@google.com>
>
> This patch adds all the necessary data structure and support
> functions to implement TFO server side. It also documents a number
> of flags for the sysctl_tcp_fastopen knob, and adds a few Linux
> extension MIBs.
>
> In addition, it includes the following:
>
> 1. a new TCP_FASTOPEN socket option an application must call to
> supply a max backlog allowed in order to enable TFO on its listener.
>
> 2. A number of key data structures:
> "fastopen_rsk" in tcp_sock - for a big socket to access its
> request_sock for retransmission and ack processing purpose. It is
> non-NULL iff 3WHS not completed.
>
> "fastopenq" in request_sock_queue - points to a per Fast Open
> listener data structure "fastopen_queue" to keep track of qlen (# of
> outstanding Fast Open requests) and max_qlen, among other things.
>
> "listener" in tcp_request_sock - to point to the original listener
> for book-keeping purpose, i.e., to maintain qlen against max_qlen
> as part of defense against IP spoofing attack.
>
> 3. various data structure and functions, many in tcp_fastopen.c, to
> support server side Fast Open cookie operations, including
> /proc/sys/net/ipv4/tcp_fastopen_key to allow manual rekeying.
>
> Signed-off-by: H.K. Jerry Chu <hkchu@google.com>
> Cc: Yuchung Cheng <ycheng@google.com>
> Cc: Neal Cardwell <ncardwell@google.com>
> Cc: Eric Dumazet <edumazet@google.com>
> Cc: Tom Herbert <therbert@google.com>
> ---
> Documentation/networking/ip-sysctl.txt | 29 ++++++++---
> include/linux/snmp.h | 4 ++
> include/linux/tcp.h | 45 ++++++++++++++++-
> include/net/request_sock.h | 36 ++++++++++++++
> include/net/tcp.h | 46 +++++++++++++++---
> net/ipv4/proc.c | 4 ++
> net/ipv4/sysctl_net_ipv4.c | 45 +++++++++++++++++
> net/ipv4/tcp_fastopen.c | 83 +++++++++++++++++++++++++++++++-
> net/ipv4/tcp_input.c | 4 +-
> 9 files changed, 276 insertions(+), 20 deletions(-)
There are two very small points that can be addressed later, or in next
iteration if there is one.
static inline bool fastopen_cookie_present(struct tcp_fastopen_cookie *foc)
{
return (foc)->len != -1;
}
should be :
static inline bool fastopen_cookie_present(const struct tcp_fastopen_cookie *foc)
{
return foc->len != -1;
}
And we should add a BUILD_BUG_ON(TCP_FASTOPEN_KEY_LENGTH != 4*sizeof(u32));
in proc_tcp_fastopen_key().
Acked-by: Eric Dumazet <edumazet@google.com>
next prev parent reply other threads:[~2012-08-31 14:22 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-08-30 23:39 [PATCH 0/3] tcp: TCP Fast Open, Server Side H.K. Jerry Chu
2012-08-30 23:39 ` [PATCH 1/3] tcp: TCP Fast Open Server - header & support functions H.K. Jerry Chu
2012-08-31 14:21 ` Eric Dumazet [this message]
2012-08-30 23:39 ` [PATCH 2/3] tcp: TCP Fast Open Server - support TFO listeners H.K. Jerry Chu
2012-08-30 23:39 ` [PATCH 3/3] tcp: TCP Fast Open Server - main code path H.K. Jerry Chu
2012-08-31 20:53 ` [PATCH 0/3] tcp: TCP Fast Open, Server Side David Miller
2012-08-31 22:27 ` Jerry Chu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1346422867.2591.47.camel@edumazet-glaptop \
--to=eric.dumazet@gmail.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=hkchu@google.com \
--cc=ncardwell@google.com \
--cc=netdev@vger.kernel.org \
--cc=sivasankar@cs.ucsd.edu \
--cc=therbert@google.com \
--cc=ycheng@google.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox