From: "R. Parameswaran" <parameswaran.r7@gmail.com>
To: David Miller <davem@davemloft.net>
Cc: kleptog@svana.org, jchapman@katalix.com, davem@redhat.com,
nprachan@brocade.com, rshearma@brocade.com,
stephen@networkplumber.org, sdietric@brocade.com,
ciwillia@brocade.com, lboccass@brocade.com, dfawcus@brocade.com,
bhong@brocade.com, jblunck@brocade.com,
linux-kernel@vger.kernel.org, netdev@vger.kernel.org
Subject: Re: [PATCH net-next v4 1/2] New kernel function to get IP overhead on a socket.
Date: Thu, 23 Mar 2017 18:51:44 -0700 (PDT) [thread overview]
Message-ID: <alpine.DEB.2.11.1703231809410.19388@vera100.eng.brocade.com> (raw)
In-Reply-To: <20170323.150500.1211908608737471263.davem@davemloft.net>
Hi Dave,
Please see inline:
On Thu, 23 Mar 2017, David Miller wrote:
> From: "R. Parameswaran" <parameswaran.r7@gmail.com>
> Date: Wed, 22 Mar 2017 15:59:13 -0700 (PDT)
>
> > A new function, kernel_sock_ip_overhead(), is provided
> > to calculate the cumulative overhead imposed by the IP
> > Header and IP options, if any, on a socket's payload.
> > The new function returns an overhead of zero for sockets
> > that do not belong to the IPv4 or IPv6 address families.
> >
> > Signed-off-by: R. Parameswaran <rparames@brocade.com>
>
> Just use the IPv4/IPv6 header size for now, just like the VXLAN
> driver does.
>
Actually, that's how the original posting was - it was changed in
response to a review comment from James Chapman requesting the IP
Options overhead to be factored in and for this to be calculated in
a new standalone function that can be reused in other situations.
The review comment makes sense to me - the kernel seems to do a
good job of accounting for the cumulative size of IP Options and
if the information is available, it may make sense to factor it in.
I guess you are concerned about compatibility between vxlan and
L2TP? There may be one difference - the socket for vxlan
appears to be opened/controlled entirely within kernel code (seems
to call udp_sock_create() which does not appear to turn on any options),
but in the case of L2TP, it is possible for the tunnel socket to be
opened from user space, if a user space control plane daemon is running.
Regardless of how user space daemons are written right now, it is
possible in theory for the user space code to turn on options on the
L2TP tunnel socket. So it seems that IP options might be enabled on the
L2TP socket, but are probably unlikely on the vxlan socket?
I'd suggest giving this a few days for James to respond.
At that time if there is agreement that we don't need to factor options,
I can rework it.
thanks,
Ramkumar
> Thanks.
>
next prev parent reply other threads:[~2017-03-24 1:52 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-03-22 22:59 R. Parameswaran
2017-03-22 23:03 ` Tom Herbert
2017-03-23 22:05 ` David Miller
2017-03-24 1:51 ` R. Parameswaran [this message]
2017-03-24 13:13 ` James Chapman
2017-04-03 20:28 ` R. Parameswaran
2017-04-03 20:30 ` David Miller
2017-04-04 2:12 ` R. Parameswaran
2017-04-04 2:19 ` David Miller
2017-03-24 1:04 ` kbuild test robot
2017-03-23 1:21 R. Parameswaran
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=alpine.DEB.2.11.1703231809410.19388@vera100.eng.brocade.com \
--to=parameswaran.r7@gmail.com \
--cc=bhong@brocade.com \
--cc=ciwillia@brocade.com \
--cc=davem@davemloft.net \
--cc=davem@redhat.com \
--cc=dfawcus@brocade.com \
--cc=jblunck@brocade.com \
--cc=jchapman@katalix.com \
--cc=kleptog@svana.org \
--cc=lboccass@brocade.com \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=nprachan@brocade.com \
--cc=rshearma@brocade.com \
--cc=sdietric@brocade.com \
--cc=stephen@networkplumber.org \
/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
all inboxes | Powered by JetHome®