]>
Commit | Line | Data |
---|---|---|
ff38683c GKH |
1 | From foo@baz Wed 15 May 2019 09:45:15 AM CEST |
2 | From: Stephen Suryaputra <ssuryaextr@gmail.com> | |
3 | Date: Mon, 6 May 2019 15:00:01 -0400 | |
4 | Subject: vrf: sit mtu should not be updated when vrf netdev is the link | |
5 | ||
6 | From: Stephen Suryaputra <ssuryaextr@gmail.com> | |
7 | ||
8 | [ Upstream commit ff6ab32bd4e073976e4d8797b4d514a172cfe6cb ] | |
9 | ||
10 | VRF netdev mtu isn't typically set and have an mtu of 65536. When the | |
11 | link of a tunnel is set, the tunnel mtu is changed from 1480 to the link | |
12 | mtu minus tunnel header. In the case of VRF netdev is the link, then the | |
13 | tunnel mtu becomes 65516. So, fix it by not setting the tunnel mtu in | |
14 | this case. | |
15 | ||
16 | Signed-off-by: Stephen Suryaputra <ssuryaextr@gmail.com> | |
17 | Reviewed-by: David Ahern <dsahern@gmail.com> | |
18 | Signed-off-by: David S. Miller <davem@davemloft.net> | |
19 | Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> | |
20 | --- | |
21 | net/ipv6/sit.c | 2 +- | |
22 | 1 file changed, 1 insertion(+), 1 deletion(-) | |
23 | ||
24 | --- a/net/ipv6/sit.c | |
25 | +++ b/net/ipv6/sit.c | |
26 | @@ -1069,7 +1069,7 @@ static void ipip6_tunnel_bind_dev(struct | |
27 | if (!tdev && tunnel->parms.link) | |
28 | tdev = __dev_get_by_index(tunnel->net, tunnel->parms.link); | |
29 | ||
30 | - if (tdev) { | |
31 | + if (tdev && !netif_is_l3_master(tdev)) { | |
32 | int t_hlen = tunnel->hlen + sizeof(struct iphdr); | |
33 | ||
34 | dev->hard_header_len = tdev->hard_header_len + sizeof(struct iphdr); |