8021q and change_mtu problem

Laurent Lagrange lagrange at fr.oleane.com
Sat Jan 29 01:29:48 EST 2005


Hello,

I have tried to use the "change_mtu" function with a 8021q network device.
I have compare this function with an other one define for ethernet devices
in /drivers/net/net_init.c.

These functions always return -EINVAL when the new mtu value is invalid.
But for a valid mtu value the first one returns the new value and the second
one returns 0.

I use a linux 2.6.9 kernel from kernel.org.

I have tried this very simple patch and the function works fine.

--- net/8021q/vlan_dev.c    Fri Jan 28 15:07:58 2005
+++ net/8021q/vlan_dev.c  Fri Jan 28 15:12:12 2005
@@ -527,7 +527,7 @@

    dev->mtu = new_mtu;

-   return new_mtu;
+   return 0;

Laurent







More information about the Linuxppc-embedded mailing list