From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.0 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 9EFAEC04E53 for ; Wed, 15 May 2019 12:02:57 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 58C5D20657 for ; Wed, 15 May 2019 12:02:57 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1557921777; bh=zhCTksgoUuUCE9snSFnxvBQeEUtUfyolWGZGsd/UIIw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-ID:From; b=PVVdaBxkHh6Yzh7Lyl8GbFb66tyvvJnMqt/u7jAkTlYfw1rvlZkkPvRbF8++Rc3Wi WdW/D2X+KWhlKe/mOo6DFLYHYP7IYa0afheLAqG/jAIkDxzTNUbM+5brHXT9ggCZWJ cpYjyJUPBoDZyv2MYox8pQwsP0vILDWY5T4nDopc= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730336AbfEOMC4 (ORCPT ); Wed, 15 May 2019 08:02:56 -0400 Received: from mail.kernel.org ([198.145.29.99]:48468 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729303AbfEOLMx (ORCPT ); Wed, 15 May 2019 07:12:53 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 4FF3220843; Wed, 15 May 2019 11:12:52 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1557918772; bh=zhCTksgoUuUCE9snSFnxvBQeEUtUfyolWGZGsd/UIIw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=xYQ7uy4QItxDbb+gTMBylKRzkgwu5R35dy/Cx8a/busIXFXKpHQAtFDiGvHZ/0ann rP2wqTx7hRqfXpuD9tqzuaMshS6Kysw0eyyqdHxwEF5sBJaFFu+IYL3gZeCsYOHW5M 3d0FC84sarXwkc9AqJ3z1rxraqfFeCM9hN2vqMpo= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Stephen Suryaputra , David Ahern , "David S. Miller" Subject: [PATCH 4.4 261/266] vrf: sit mtu should not be updated when vrf netdev is the link Date: Wed, 15 May 2019 12:56:08 +0200 Message-Id: <20190515090731.846459420@linuxfoundation.org> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20190515090722.696531131@linuxfoundation.org> References: <20190515090722.696531131@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Stephen Suryaputra [ Upstream commit ff6ab32bd4e073976e4d8797b4d514a172cfe6cb ] VRF netdev mtu isn't typically set and have an mtu of 65536. When the link of a tunnel is set, the tunnel mtu is changed from 1480 to the link mtu minus tunnel header. In the case of VRF netdev is the link, then the tunnel mtu becomes 65516. So, fix it by not setting the tunnel mtu in this case. Signed-off-by: Stephen Suryaputra Reviewed-by: David Ahern Signed-off-by: David S. Miller Signed-off-by: Greg Kroah-Hartman --- net/ipv6/sit.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/net/ipv6/sit.c +++ b/net/ipv6/sit.c @@ -1076,7 +1076,7 @@ static void ipip6_tunnel_bind_dev(struct if (!tdev && tunnel->parms.link) tdev = __dev_get_by_index(tunnel->net, tunnel->parms.link); - if (tdev) { + if (tdev && !netif_is_l3_master(tdev)) { int t_hlen = tunnel->hlen + sizeof(struct iphdr); dev->hard_header_len = tdev->hard_header_len + sizeof(struct iphdr);