WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] [PATCH] set mtu from bridge also on vif interface

To: Olaf Hering <olaf@xxxxxxxxx>
Subject: Re: [Xen-devel] [PATCH] set mtu from bridge also on vif interface
From: Ian Campbell <Ian.Campbell@xxxxxxxxxx>
Date: Mon, 7 Feb 2011 09:07:18 +0000
Cc: "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>
Delivery-date: Mon, 07 Feb 2011 01:08:44 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <20110206134123.GA9752@xxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Organization: Citrix Systems, Inc.
References: <20110206134123.GA9752@xxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
On Sun, 2011-02-06 at 13:41 +0000, Olaf Hering wrote:
> Apply mtu size from bridge interface also in vif interface.
> This depends on a kernel change which allows arbitrary mtu sizes until
> the frontend driver has connected to the backend driver. Without this
> kernel change, the vif mtu size will be limited to 1500 even with this
> change to the vif-bridge script.
> 
> Signed-off-by: Olaf Hering <olaf@xxxxxxxxx>

In my experience the bridge will only allow it's MTU to be set to the
minimum of all the ports (or 1500ish if there are no ports) and will
reset to the new minimum when you add a new port.

So does this patch do anything in the absence of the ability to
configure the MTU of a VIF from the toolstack?

Ian.

> 
> ---
>  tools/hotplug/Linux/vif-bridge |    5 +++++
>  1 file changed, 5 insertions(+)
> 
> --- xen-unstable.hg-4.1.22870.orig/tools/hotplug/Linux/vif-bridge
> +++ xen-unstable.hg-4.1.22870/tools/hotplug/Linux/vif-bridge
> @@ -82,6 +82,11 @@ fi
>  case "$command" in
>      online)
>          setup_virtual_bridge_port "$dev"
> +        mtu="`ip link show $bridge | awk '/mtu/ { print $5 }'`"
> +        if [ -n "$mtu" ] && [ "$mtu" -gt 0 ]
> +        then
> +                ip link set $dev mtu $mtu || :
> +        fi
>          add_to_bridge "$bridge" "$dev"
>          ;;
>  
> 
> _______________________________________________
> Xen-devel mailing list
> Xen-devel@xxxxxxxxxxxxxxxxxxx
> http://lists.xensource.com/xen-devel



_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel