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

[Xen-changelog] Patch ipv4 netfilter code to avoid checksumming CHECKUM_

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] Patch ipv4 netfilter code to avoid checksumming CHECKUM_UNNCECESSARY
From: BitKeeper Bot <riel@xxxxxxxxxxx>
Date: Fri, 27 May 2005 10:51:06 +0000
Delivery-date: Fri, 27 May 2005 11:00:42 +0000
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: Xen Development List <xen-devel@xxxxxxxxxxxxxxxxxxx>
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
ChangeSet 1.1575, 2005/05/27 11:51:06+01:00, kaf24@xxxxxxxxxxxxxxxxxxxx

        Patch ipv4 netfilter code to avoid checksumming CHECKUM_UNNCECESSARY
        packets. On Xen the check could fail, as packets from domU have a blank
        checksum field.
        Signed-off-by: Keir Fraser <keir@xxxxxxxxxxxxx>



 net-csum.patch |   18 ++++++++++++++++++
 1 files changed, 18 insertions(+)


diff -Nru a/patches/linux-2.6.11/net-csum.patch 
b/patches/linux-2.6.11/net-csum.patch
--- /dev/null   Wed Dec 31 16:00:00 196900
+++ b/patches/linux-2.6.11/net-csum.patch       2005-05-27 07:01:30 -04:00
@@ -0,0 +1,22 @@
+diff -ur linux-2.6.11/net/ipv4/netfilter/ip_conntrack_proto_tcp.c 
linux-2.6.11-csum/net/ipv4/netfilter/ip_conntrack_proto_tcp.c
+--- linux-2.6.11/net/ipv4/netfilter/ip_conntrack_proto_tcp.c   2005-05-27 
11:47:48 +01:00
++++ linux-2.6.11-csum/net/ipv4/netfilter/ip_conntrack_proto_tcp.c      
2005-05-27 11:48:07 +01:00
+@@ -803,6 +803,7 @@
+        */
+       /* FIXME: Source route IP option packets --RR */
+       if (hooknum == NF_IP_PRE_ROUTING
++          && skb->ip_summed != CHECKSUM_UNNECESSARY
+           && csum_tcpudp_magic(iph->saddr, iph->daddr, tcplen, IPPROTO_TCP,
+                                skb->ip_summed == CHECKSUM_HW ? skb->csum
+                                : skb_checksum(skb, iph->ihl*4, tcplen, 0))) {
+diff -ur linux-2.6.11/net/ipv4/netfilter/ip_conntrack_proto_udp.c 
linux-2.6.11-csum/net/ipv4/netfilter/ip_conntrack_proto_udp.c
+--- linux-2.6.11/net/ipv4/netfilter/ip_conntrack_proto_udp.c   2005-05-27 
11:47:48 +01:00
++++ linux-2.6.11-csum/net/ipv4/netfilter/ip_conntrack_proto_udp.c      
2005-05-27 11:48:07 +01:00
+@@ -120,6 +120,7 @@
+        * and moreover root might send raw packets.
+        * FIXME: Source route IP option packets --RR */
+       if (hooknum == NF_IP_PRE_ROUTING
++          && skb->ip_summed != CHECKSUM_UNNECESSARY
+           && csum_tcpudp_magic(iph->saddr, iph->daddr, udplen, IPPROTO_UDP,
+                                skb->ip_summed == CHECKSUM_HW ? skb->csum
+                                : skb_checksum(skb, iph->ihl*4, udplen, 0))) {

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] Patch ipv4 netfilter code to avoid checksumming CHECKUM_UNNCECESSARY, BitKeeper Bot <=