Lines Matching refs:sum

39 static inline __sum16 csum_fold(__wsum sum)  in csum_fold()  argument
41 u32 tmp = (__force u32)sum; in csum_fold()
58 __u8 proto, __wsum sum) in csum_tcpudp_nofold() argument
61 u64 s = (__force u32)sum; in csum_tcpudp_nofold()
78 : "=r" (sum) in csum_tcpudp_nofold()
79 : "r" (daddr), "r"(saddr), "r"(proto + len), "0"(sum)); in csum_tcpudp_nofold()
80 return sum; in csum_tcpudp_nofold()
89 __u8 proto, __wsum sum) in csum_tcpudp_magic() argument
91 return csum_fold(csum_tcpudp_nofold(saddr, daddr, len, proto, sum)); in csum_tcpudp_magic()
116 static __always_inline __wsum csum_shift(__wsum sum, int offset) in csum_shift() argument
119 return (__force __wsum)rol32((__force u32)sum, (offset & 1) << 3); in csum_shift()
138 __wsum sum, tmp; in ip_fast_csum_nofold() local
146 : "=r" (sum), "=r" (tmp), "+b" (ptr) in ip_fast_csum_nofold()
150 return sum; in ip_fast_csum_nofold()
171 __wsum __csum_partial(const void *buff, int len, __wsum sum);
173 static __always_inline __wsum csum_partial(const void *buff, int len, __wsum sum) in csum_partial() argument
177 sum = csum_add(sum, (__force __wsum)*(const u16 *)buff); in csum_partial()
179 sum = csum_add(sum, (__force __wsum)*(const u32 *)buff); in csum_partial()
181 sum = csum_add(sum, (__force __wsum) in csum_partial()
184 sum = csum_add(sum, (__force __wsum) in csum_partial()
187 sum = csum_add(sum, (__force __wsum) in csum_partial()
190 sum = csum_add(sum, (__force __wsum) in csum_partial()
193 sum = csum_add(sum, (__force __wsum) in csum_partial()
196 sum = csum_add(sum, (__force __wsum) in csum_partial()
199 sum = csum_add(sum, ip_fast_csum_nofold(buff, len >> 2)); in csum_partial()
201 sum = __csum_partial(buff, len, sum); in csum_partial()
203 return sum; in csum_partial()
218 __u32 len, __u8 proto, __wsum sum);