--- /home/carlos/Builds/UCLINUX/uclinux-2.4.x/include/asm-m68knommu/checksum.h Fri Jan 5 19:53:31 2001 +++ include/asm-m68knommu/checksum.h Thu Feb 21 12:00:23 2002 @@ -51,7 +51,7 @@ ip_fast_csum(unsigned char *iph, unsigned int ihl) { unsigned int sum = 0; - +#ifndef CONFIG_COLDFIRE __asm__ ("subqw #1,%2\n" "1:\t" "movel %1@+,%/d0\n\t" @@ -65,6 +65,22 @@ : "=d" (sum), "=a" (iph), "=d" (ihl) : "0" (sum), "1" (iph), "2" (ihl) : "d0"); +#else + __asm__ ("subql #1,%2\n" + "1:\t" + "movel %1@+,%/d0\n\t" + "addxl %/d0,%0\n\t" + "subql #1,%2\n\t" + "bra 1b\n\t" + "movel %0,%/d0\n\t" + "swap %/d0\n\t" + "addxl %/d0,%0\n\t" + "clrw %/d0\n\t" + "addxl %/d0,%0\n\t" + : "=d" (sum), "=a" (iph), "=d" (ihl) + : "0" (sum), "1" (iph), "2" (ihl) + : "d0"); +#endif return ~sum; } #endif