Lines Matching full:sum
20 * and adds in "sum" (32-bit).
30 static inline __wsum csum_partial(const void *buff, int len, __wsum sum) in csum_partial() argument
38 "0: cksm %[sum],%[rp]\n" in csum_partial()
40 : [sum] "+&d" (sum), [rp] "+&d" (rp.pair) : : "cc", "memory"); in csum_partial()
41 return sum; in csum_partial()
47 static inline __sum16 csum_fold(__wsum sum) in csum_fold() argument
49 u32 csum = (__force u32) sum; in csum_fold()
81 __u8 proto, __wsum sum) in csum_tcpudp_nofold() argument
83 __u64 csum = (__force __u64)sum; in csum_tcpudp_nofold()
98 __u8 proto, __wsum sum) in csum_tcpudp_magic() argument
100 return csum_fold(csum_tcpudp_nofold(saddr, daddr, len, proto, sum)); in csum_tcpudp_magic()
116 __u64 sum = (__force __u64)csum; in csum_ipv6_magic() local
118 sum += (__force __u32)saddr->s6_addr32[0]; in csum_ipv6_magic()
119 sum += (__force __u32)saddr->s6_addr32[1]; in csum_ipv6_magic()
120 sum += (__force __u32)saddr->s6_addr32[2]; in csum_ipv6_magic()
121 sum += (__force __u32)saddr->s6_addr32[3]; in csum_ipv6_magic()
122 sum += (__force __u32)daddr->s6_addr32[0]; in csum_ipv6_magic()
123 sum += (__force __u32)daddr->s6_addr32[1]; in csum_ipv6_magic()
124 sum += (__force __u32)daddr->s6_addr32[2]; in csum_ipv6_magic()
125 sum += (__force __u32)daddr->s6_addr32[3]; in csum_ipv6_magic()
126 sum += len; in csum_ipv6_magic()
127 sum += proto; in csum_ipv6_magic()
128 sum += (sum >> 32) | (sum << 32); in csum_ipv6_magic()
129 return csum_fold((__force __wsum)(sum >> 32)); in csum_ipv6_magic()