summaryrefslogtreecommitdiff
path: root/arch/mips/include/asm/checksum.h
diff options
context:
space:
mode:
Diffstat (limited to 'arch/mips/include/asm/checksum.h')
-rw-r--r--arch/mips/include/asm/checksum.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/mips/include/asm/checksum.h b/arch/mips/include/asm/checksum.h
index dcebaaf8c862..181f7d14efb9 100644
--- a/arch/mips/include/asm/checksum.h
+++ b/arch/mips/include/asm/checksum.h
@@ -113,9 +113,9 @@ static inline __sum16 csum_fold(__wsum csum)
u32 sum = (__force u32)csum;
sum += (sum << 16);
- csum = (sum < csum);
+ csum = (__force __wsum)(sum < (__force u32)csum);
sum >>= 16;
- sum += csum;
+ sum += (__force u32)csum;
return (__force __sum16)~sum;
}