]> git.hungrycats.org Git - linux/commitdiff
[PATCH] multicast broken on x86_64
authorBrian Childs <brian@rentec.com>
Thu, 26 Feb 2004 05:26:23 +0000 (21:26 -0800)
committerLinus Torvalds <torvalds@ppc970.osdl.org>
Thu, 26 Feb 2004 05:26:23 +0000 (21:26 -0800)
The x86-64 implementation of csum-partial.c causes it to compute the
checksum incorrectly.

As a result, multicast doesn't work.  It looks as though iptables is
also affected.

Here's a simple patch.

arch/x86_64/lib/csum-partial.c

index 860d5e2d90f1401681cf16f2a81adb77e040df66..5384e227cdf6197166e29de0893d2938f63ebb68 100644 (file)
@@ -145,6 +145,6 @@ EXPORT_SYMBOL(csum_partial);
  */
 unsigned short ip_compute_csum(unsigned char * buff, int len)
 {
-       return ~csum_partial(buff,len,0); 
+       return csum_fold(csum_partial(buff,len,0));
 }