]> xenbits.xensource.com Git - people/ssmith/nc2-2.6.27.bak/.git/commitdiff
patch forward-port-s2io.patch
authorSteven Smith <ssmith@weybridge.uk.xensource.com>
Thu, 28 May 2009 10:54:19 +0000 (11:54 +0100)
committerSteven Smith <ssmith@weybridge.uk.xensource.com>
Thu, 28 May 2009 10:54:19 +0000 (11:54 +0100)
drivers/net/s2io.c

index 35b9c183fb60c748fe318946b3d151da4ef05c66..6d5c62c097ce1b8ef44874822647ccb576d0dbba 100644 (file)
@@ -11214,17 +11214,21 @@ static int check_L2_lro_capable(u8 *buffer, struct iphdr **ip,
                        /* Check if it is a vlan packet */
                        if (ring->vlgrp && vid) {
                                struct net_device *vlan_dev = NULL;
-                               struct vlan_dev_info *vlan_info = NULL;
-
 #if (LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 21))
+
                                vlan_dev =
                                        vlan_group_get_device(ring->vlgrp, vid);
 #else
+                               struct vlan_dev_info *vlan_info = NULL;
                                vlan_dev = ring->vlgrp->vlan_devices[vid];
 #endif
                                if (!vlan_dev)
                                        goto donot_aggr;
 
+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 27))
+                               if (vlan_dev_real_dev(vlan_dev) != ring->dev)
+                                       return 0;
+#else
                                vlan_info = 
                                        (struct vlan_dev_info *)(vlan_dev->priv);
                                if (!vlan_info)
@@ -11233,6 +11237,7 @@ static int check_L2_lro_capable(u8 *buffer, struct iphdr **ip,
                                /* Is this a registered vlan? */
                                if (vlan_info->real_dev == ring->dev)
                                        return 0;
+#endif
                        }
 
 donot_aggr: