From: William Dauchy <w.dauchy@criteo.com>
To: Nicolas Dichtel <nicolas.dichtel@6wind.com>
Cc: netdev@vger.kernel.org
Subject: Re: [PATCH v3 net] net, ip6_tunnel: enhance tunnel locate with link check
Date: Wed, 12 Feb 2020 22:06:47 +0100 [thread overview]
Message-ID: <20200212210647.GB159357@dontpanic> (raw)
In-Reply-To: <ce1f9fbe-a28a-d5c3-c792-ded028df52e5@6wind.com>
Hello Nicolas,
Thank you for your review.
On Wed, Feb 12, 2020 at 04:54:19PM +0100, Nicolas Dichtel wrote:
> Hmm, I was expecting 'tdev->mtu - t_hlen'. Am I wrong?
>
> In fact, something like this:
> dev->mtu = ETH_DATA_LEN - t_hlen;
> if (t->parms.link) {
> tdev = __dev_get_by_index(t->net, t->parms.link);
> if (tdev)
> dev->mtu = tdev->mtu - t_hlen;
> }
true, I missed that one; I reworked to something like:
int mtu;
mtu = ETH_DATA_LEN;
if (t->parms.link) {
tdev = __dev_get_by_index(t->net, t->parms.link);
if (tdev && tdev->mtu < mtu)
mtu = tdev->mtu;
}
dev->mtu = mtu - t_hlen;
However in ipip we do:
mtu -= (dev->hard_header_len + t_hlen);
Do I need to use hard_header_len as well?
Thanks,
--
William
next prev parent reply other threads:[~2020-02-12 21:06 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-02-05 14:57 [PATCH] net, ip6_tunnel: enhance tunnel locate with link/type check William Dauchy
2020-02-05 15:04 ` Nicolas Dichtel
2020-02-05 16:29 ` [PATCH v2 0/2] net, ip6_tunnel: enhance tunnel locate William Dauchy
2020-02-05 16:29 ` [PATCH v2 1/2] net, ip6_tunnel: enhance tunnel locate with link check William Dauchy
2020-02-05 16:54 ` Nicolas Dichtel
2020-02-05 17:36 ` William Dauchy
2020-02-12 8:30 ` [PATCH v3 net] " William Dauchy
2020-02-12 15:54 ` Nicolas Dichtel
2020-02-12 21:06 ` William Dauchy [this message]
2020-02-13 9:34 ` Nicolas Dichtel
2020-02-13 15:26 ` William Dauchy
2020-02-13 15:35 ` [PATCH v4 " William Dauchy
2020-02-13 16:33 ` Nicolas Dichtel
2020-02-13 17:19 ` [PATCH v5 " William Dauchy
2020-02-14 9:50 ` Nicolas Dichtel
2020-02-14 15:32 ` David Miller
2020-02-05 16:29 ` [PATCH v2 2/2] net, ip6_tunnel: enhance tunnel locate with type check William Dauchy
2020-02-05 16:59 ` Nicolas Dichtel
2020-02-05 17:31 ` William Dauchy
2020-02-05 18:16 ` William Dauchy
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=20200212210647.GB159357@dontpanic \
--to=w.dauchy@criteo.com \
--cc=netdev@vger.kernel.org \
--cc=nicolas.dichtel@6wind.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;
as well as URLs for NNTP newsgroup(s).