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-users

[Xen-devel] [PATCH] netback vlan support [WAS: Re: [Xen-users] Ethernet

To: xen-users@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-devel] [PATCH] netback vlan support [WAS: Re: [Xen-users] Ethernet MTU]
From: Daniele Palumbo <daniele@xxxxxxxxxxxx>
Date: Thu, 14 Sep 2006 20:12:02 +0200
Cc: xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxx>
Delivery-date: Thu, 14 Sep 2006 11:15:47 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <200609131655.20244.daniele@xxxxxxxxxxxx>
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/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <00c801c6c11c$a2c62ee0$2f00a8c0@ELTON> <20060816205306.GA15396@xxxxxxx> <200609131655.20244.daniele@xxxxxxxxxxxx>
Reply-to: daniele@xxxxxxxxxxxx
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: KMail/1.8.2
On Wednesday 13 September 2006 16:55, Daniele Palumbo wrote:
I made a working patch (tested by me, icmp and tcp).
This work *WITH* netfront_vlan.patch.

simply, the patch will use VLAN_ETH_FRAME_LEN (1518 bytes) instead of 
ETH_FRAME_LEN (1514 bytes).
this patch will involve (for clear code) common.h (including vlans headers) 
and netback.c (using #define in vlans headers ;), both in driver netback 
directory.

this is something like "quick and dirthy", what do you think about it?

HTH
bye
d.

> netfront_vlan.patch:
> ---
> # Node ID a5ee1cb525bbe8954dc3332ceec951e09a378b68
> # parent: c097485037f7417b77db34da198b62a9c9481dc5
> Make MTU rx check in netfront more permissive to allow for 8021q vlan
> tagging.
>
> Signed-off-by: Keir Fraser <keir@xxxxxxxxxxxxx>
>
> --- a/linux-2.6-xen-sparse/drivers/xen/netfront/netfront.c      Wed Mar 15
> 12:41:58 2006 +0100
> +++ b/linux-2.6-xen-sparse/drivers/xen/netfront/netfront.c      Wed Mar 15
> 12:52:33 2006 +0100
> @@ -845,11 +845,11 @@ static int netif_poll(struct net_device
>         }
>
>         while ((skb = __skb_dequeue(&rxq)) != NULL) {
> -               if (skb->len > (dev->mtu + ETH_HLEN)) {
> +               if (skb->len > (dev->mtu + ETH_HLEN + 4)) {
>                         if (net_ratelimit())
>                                 printk(KERN_INFO "Received packet too big
> for "
>                                        "MTU (%d > %d)\n",
> -                                      skb->len - ETH_HLEN, dev->mtu);
> +                                      skb->len - ETH_HLEN - 4, dev->mtu);
>                         skb->len  = 0;
>                         skb->tail = skb->data;
>                         init_skb_shinfo(skb);
> ---

-- 
PGP Key-ID: 0xF482D454
--
to boldly go where no man has gone before.

Attachment: netback_vlan.patch
Description: Text Data

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
<Prev in Thread] Current Thread [Next in Thread>