netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ip6erspan: remove the incorrect mtu limit for ip6erspan
@ 2019-10-08  9:56 Haishuang Yan
  2019-10-08 16:14 ` William Tu
  2019-10-09  2:53 ` Jakub Kicinski
  0 siblings, 2 replies; 3+ messages in thread
From: Haishuang Yan @ 2019-10-08  9:56 UTC (permalink / raw)
  To: David S. Miller; +Cc: William Tu, netdev, linux-kernel, Haishuang Yan

ip6erspan driver calls ether_setup(), after commit 61e84623ace3
("net: centralize net_device min/max MTU checking"), the range
of mtu is [min_mtu, max_mtu], which is [68, 1500] by default.

It causes the dev mtu of the erspan device to not be greater
than 1500, this limit value is not correct for ip6erspan tap
device.

Signed-off-by: Haishuang Yan <yanhaishuang@cmss.chinamobile.com>
---
 net/ipv6/ip6_gre.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/net/ipv6/ip6_gre.c b/net/ipv6/ip6_gre.c
index d5779d6..787d9f2 100644
--- a/net/ipv6/ip6_gre.c
+++ b/net/ipv6/ip6_gre.c
@@ -2192,6 +2192,7 @@ static void ip6erspan_tap_setup(struct net_device *dev)
 {
 	ether_setup(dev);
 
+	dev->max_mtu = 0;
 	dev->netdev_ops = &ip6erspan_netdev_ops;
 	dev->needs_free_netdev = true;
 	dev->priv_destructor = ip6gre_dev_free;
-- 
1.8.3.1




^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] ip6erspan: remove the incorrect mtu limit for ip6erspan
  2019-10-08  9:56 [PATCH] ip6erspan: remove the incorrect mtu limit for ip6erspan Haishuang Yan
@ 2019-10-08 16:14 ` William Tu
  2019-10-09  2:53 ` Jakub Kicinski
  1 sibling, 0 replies; 3+ messages in thread
From: William Tu @ 2019-10-08 16:14 UTC (permalink / raw)
  To: Haishuang Yan; +Cc: David S. Miller, netdev, linux-kernel

On Tue, Oct 08, 2019 at 05:56:03PM +0800, Haishuang Yan wrote:
> ip6erspan driver calls ether_setup(), after commit 61e84623ace3
> ("net: centralize net_device min/max MTU checking"), the range
> of mtu is [min_mtu, max_mtu], which is [68, 1500] by default.
> 
> It causes the dev mtu of the erspan device to not be greater
> than 1500, this limit value is not correct for ip6erspan tap
> device.
> 
> Signed-off-by: Haishuang Yan <yanhaishuang@cmss.chinamobile.com>

Thanks for the patch.

Acked-by: William Tu <u9012063@gmail.com>

> ---
>  net/ipv6/ip6_gre.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/net/ipv6/ip6_gre.c b/net/ipv6/ip6_gre.c
> index d5779d6..787d9f2 100644
> --- a/net/ipv6/ip6_gre.c
> +++ b/net/ipv6/ip6_gre.c
> @@ -2192,6 +2192,7 @@ static void ip6erspan_tap_setup(struct net_device *dev)
>  {
>  	ether_setup(dev);
>  
> +	dev->max_mtu = 0;
>  	dev->netdev_ops = &ip6erspan_netdev_ops;
>  	dev->needs_free_netdev = true;
>  	dev->priv_destructor = ip6gre_dev_free;
> -- 
> 1.8.3.1
> 
> 
> 

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] ip6erspan: remove the incorrect mtu limit for ip6erspan
  2019-10-08  9:56 [PATCH] ip6erspan: remove the incorrect mtu limit for ip6erspan Haishuang Yan
  2019-10-08 16:14 ` William Tu
@ 2019-10-09  2:53 ` Jakub Kicinski
  1 sibling, 0 replies; 3+ messages in thread
From: Jakub Kicinski @ 2019-10-09  2:53 UTC (permalink / raw)
  To: Haishuang Yan; +Cc: David S. Miller, William Tu, netdev, linux-kernel

On Tue,  8 Oct 2019 17:56:03 +0800, Haishuang Yan wrote:
> ip6erspan driver calls ether_setup(), after commit 61e84623ace3
> ("net: centralize net_device min/max MTU checking"), the range
> of mtu is [min_mtu, max_mtu], which is [68, 1500] by default.
> 
> It causes the dev mtu of the erspan device to not be greater
> than 1500, this limit value is not correct for ip6erspan tap
> device.
> 
> Signed-off-by: Haishuang Yan <yanhaishuang@cmss.chinamobile.com>

Applied, but next time please make sure you add a Fixes tag, 
and put [PATCH net] in the subject for bug fixes. Thanks!

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2019-10-09  2:53 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-10-08  9:56 [PATCH] ip6erspan: remove the incorrect mtu limit for ip6erspan Haishuang Yan
2019-10-08 16:14 ` William Tu
2019-10-09  2:53 ` Jakub Kicinski

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).