Date: Thu, 12 Jul 2012 14:26:08 -0400 From: Andrew Boyer <aboyer@averesystems.com> To: Jason Hellenthal <jhellenthal@dataix.net> Cc: George Neville-Neil <gnn@freebsd.org>, Navdeep Parhar <np@freebsd.org>, net@freebsd.org Subject: Re: Interface MTU question... Message-ID: <1AD62103-2ABF-4F07-B9EE-AD3EBF7024D5@averesystems.com> In-Reply-To: <20120712165502.GA61341@DataIX.net> References: <86liiqrnnq.wl%gnn@neville-neil.com> <4FFDF6C7.3030301@FreeBSD.org> <C06D346A-97BE-4498-B4E5-0ED85731A8BD@freebsd.org> <20120712165502.GA61341@DataIX.net>
next in thread | previous in thread | raw e-mail | index | archive | help
On Jul 12, 2012, at 12:55 PM, Jason Hellenthal wrote:
> Something else to look into ...
>
> # ifconfig lagg0 mtu 1492
> ifconfig: ioctl (set mtu): Invalid argument
>
> This is on stable/8 r238264 when the interface was up/up and down/down
>
> Also attempted on the member interfaces dc0 and dc1
It's disabled by default, but I don't know why. This seems to work for us.
-Andrew
Index: sys/net/if_lagg.c
===================================================================
--- sys/net/if_lagg.c (revision 238402)
+++ sys/net/if_lagg.c (working copy)
@@ -752,8 +752,18 @@
break;
case SIOCSIFMTU:
- /* Do not allow the MTU to be changed once joined */
- error = EINVAL;
+ LAGG_WLOCK(sc);
+ SLIST_FOREACH(lp, &sc->sc_ports, lp_entries) {
+ if (!error) {
+ /* Call the base ioctl for each port */
+ error = (*lp->lp_ioctl)(lp->lp_ifp, cmd, data);
+ }
+ }
+ if (!error) {
+ /* Update the aggregate MTU */
+ sc->sc_ifp->if_mtu = ifr->ifr_mtu;
+ }
+ LAGG_WUNLOCK(sc);
break;
default:
--------------------------------------------------
Andrew Boyer aboyer@averesystems.com
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1AD62103-2ABF-4F07-B9EE-AD3EBF7024D5>
