Commit 612ad078 authored by Heiko Carstens's avatar Heiko Carstens Committed by Vasily Gorbik

s390/checksum: have consistent calculations

Use "|" instead of "+" within csum_fold() for consistency reasons,
like in the rest of the file.
Signed-off-by: default avatarHeiko Carstens <hca@linux.ibm.com>
Signed-off-by: default avatarVasily Gorbik <gor@linux.ibm.com>
parent 614b4f5d
...@@ -54,7 +54,7 @@ static inline __sum16 csum_fold(__wsum sum) ...@@ -54,7 +54,7 @@ static inline __sum16 csum_fold(__wsum sum)
{ {
u32 csum = (__force u32) sum; u32 csum = (__force u32) sum;
csum += (csum >> 16) + (csum << 16); csum += (csum >> 16) | (csum << 16);
csum >>= 16; csum >>= 16;
return (__force __sum16) ~csum; return (__force __sum16) ~csum;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment