[kernel] r12086 - in dists/sid/linux-2.6/debian: . patches/bugfix/all patches/series

Martin Michlmayr tbm at alioth.debian.org
Sun Aug 17 12:58:48 UTC 2008


Author: tbm
Date: Sun Aug 17 12:58:46 2008
New Revision: 12086

Log:
Fix regressions caused by the "use software GSO for SG+CSUM capable
netdevices" patch


Added:
   dists/sid/linux-2.6/debian/patches/bugfix/all/loopback-enable-tso.patch
   dists/sid/linux-2.6/debian/patches/bugfix/all/net-preserve-netfilter-attributes.patch
Modified:
   dists/sid/linux-2.6/debian/changelog
   dists/sid/linux-2.6/debian/patches/series/3

Modified: dists/sid/linux-2.6/debian/changelog
==============================================================================
--- dists/sid/linux-2.6/debian/changelog	(original)
+++ dists/sid/linux-2.6/debian/changelog	Sun Aug 17 12:58:46 2008
@@ -11,6 +11,11 @@
 
   [ Martin Michlmayr ]
   * Fix PCIe on the Kurobox Pro (Lennert Buytenhek).
+  * Fix regressions caused by the "use software GSO for SG+CSUM capable
+    netdevices" patch:
+    - loopback: Enable TSO (Herbert Xu)
+    - net: Preserve netfilter attributes in skb_gso_segment using
+      __copy_skb_header (Herbert Xu)
 
   [ Bastian Blank ]
   * [armel/versatile] Override ABI changes.

Added: dists/sid/linux-2.6/debian/patches/bugfix/all/loopback-enable-tso.patch
==============================================================================
--- (empty file)
+++ dists/sid/linux-2.6/debian/patches/bugfix/all/loopback-enable-tso.patch	Sun Aug 17 12:58:46 2008
@@ -0,0 +1,43 @@
+On Fri, Aug 15, 2008 at 06:14:42PM +1000, Herbert Xu wrote:
+> 
+> It's OK, I can reproduce it now.
+
+This fixes it for me.
+
+loopback: Enable TSO
+
+This patch enables TSO since the loopback device is naturally
+capable of handling packets of any size.  This also means that
+we won't enable GSO on lo which is good until GSO is fixed to
+preserve netfilter state as netfilter treats loopback packets
+in a special way.
+
+Signed-off-by: Herbert Xu <herbert at gondor.apana.org.au>
+
+I'll work on the netfilter state preservation next.
+
+Cheers,
+-- 
+Visit Openswan at http://www.openswan.org/
+Email: Herbert Xu ~{PmV>HI~} <herbert at gondor.apana.org.au>
+Home Page: http://gondor.apana.org.au/~herbert/
+PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
+--
+diff --git a/drivers/net/loopback.c b/drivers/net/loopback.c
+index 49f6bc0..c11e621 100644
+--- a/drivers/net/loopback.c
++++ b/drivers/net/loopback.c
+@@ -234,9 +231,7 @@ static void loopback_setup(struct net_device *dev)
+ 	dev->type		= ARPHRD_LOOPBACK;	/* 0x0001*/
+ 	dev->flags		= IFF_LOOPBACK;
+ 	dev->features 		= NETIF_F_SG | NETIF_F_FRAGLIST
+-#ifdef LOOPBACK_TSO
+ 		| NETIF_F_TSO
+-#endif
+ 		| NETIF_F_NO_CSUM
+ 		| NETIF_F_HIGHDMA
+ 		| NETIF_F_LLTX
+--
+To unsubscribe from this list: send the line "unsubscribe netdev" in
+the body of a message to majordomo at vger.kernel.org
+More majordomo info at  http://vger.kernel.org/majordomo-info.html

Added: dists/sid/linux-2.6/debian/patches/bugfix/all/net-preserve-netfilter-attributes.patch
==============================================================================
--- (empty file)
+++ dists/sid/linux-2.6/debian/patches/bugfix/all/net-preserve-netfilter-attributes.patch	Sun Aug 17 12:58:46 2008
@@ -0,0 +1,65 @@
+On Fri, Aug 15, 2008 at 08:32:35PM +1000, Herbert Xu wrote:
+> 
+> I'll work on the netfilter state preservation next.
+
+Here it is:
+
+net: Preserve netfilter attributes in skb_gso_segment using __copy_skb_header
+
+skb_gso_segment didn't preserve some attributes in the original skb
+such as the netfilter fields.  This was harmless until they were used
+which is the case for packets going through lo.
+
+This patch makes it call __copy_skb_header which also picks up some
+other missing attributes.
+
+Signed-off-by: Herbert Xu <herbert at gondor.apana.org.au>
+
+diff --git a/net/core/skbuff.c b/net/core/skbuff.c
+index 8464017..ca1ccdf 100644
+--- a/net/core/skbuff.c
++++ b/net/core/skbuff.c
+@@ -2256,14 +2256,7 @@ struct sk_buff *skb_segment(struct sk_buff *skb, int features)
+ 			segs = nskb;
+ 		tail = nskb;
+ 
+-		nskb->dev = skb->dev;
+-		skb_copy_queue_mapping(nskb, skb);
+-		nskb->priority = skb->priority;
+-		nskb->protocol = skb->protocol;
+-		nskb->vlan_tci = skb->vlan_tci;
+-		nskb->dst = dst_clone(skb->dst);
+-		memcpy(nskb->cb, skb->cb, sizeof(skb->cb));
+-		nskb->pkt_type = skb->pkt_type;
++		__copy_skb_header(nskb, skb);
+ 		nskb->mac_len = skb->mac_len;
+ 
+ 		skb_reserve(nskb, headroom);
+@@ -2274,6 +2267,7 @@ struct sk_buff *skb_segment(struct sk_buff *skb, int features)
+ 		skb_copy_from_linear_data(skb, skb_put(nskb, doffset),
+ 					  doffset);
+ 		if (!sg) {
++			nskb->ip_summed = CHECKSUM_NONE;
+ 			nskb->csum = skb_copy_and_csum_bits(skb, offset,
+ 							    skb_put(nskb, len),
+ 							    len, 0);
+@@ -2283,8 +2277,6 @@ struct sk_buff *skb_segment(struct sk_buff *skb, int features)
+ 		frag = skb_shinfo(nskb)->frags;
+ 		k = 0;
+ 
+-		nskb->ip_summed = CHECKSUM_PARTIAL;
+-		nskb->csum = skb->csum;
+ 		skb_copy_from_linear_data_offset(skb, offset,
+ 						 skb_put(nskb, hsize), hsize);
+ 
+
+Cheers,
+-- 
+Visit Openswan at http://www.openswan.org/
+Email: Herbert Xu ~{PmV>HI~} <herbert at gondor.apana.org.au>
+Home Page: http://gondor.apana.org.au/~herbert/
+PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
+--
+To unsubscribe from this list: send the line "unsubscribe netdev" in
+the body of a message to majordomo at vger.kernel.org
+More majordomo info at  http://vger.kernel.org/majordomo-info.html

Modified: dists/sid/linux-2.6/debian/patches/series/3
==============================================================================
--- dists/sid/linux-2.6/debian/patches/series/3	(original)
+++ dists/sid/linux-2.6/debian/patches/series/3	Sun Aug 17 12:58:46 2008
@@ -1,3 +1,5 @@
 - bugfix/arm/kurobox_fix_nr_controllers.patch
 + bugfix/arm/kurobox_ignore_pci.patch
 + bugfix/x86-amd-opteron-tom2-mask-val-fix.patch
++ bugfix/all/loopback-enable-tso.patch
++ bugfix/all/net-preserve-netfilter-attributes.patch



More information about the Kernel-svn-changes mailing list