Lines Matching +full:compute +full:-
1 /* SPDX-License-Identifier: GPL-2.0 */
31 /* +ve: Passed to listen() as-is.
35 * Most tests only have one on-going connection.
36 * -ve: It is changed to 0 before passing to listen().
94 * open_netns() - Switch to specified network namespace by name.
106 * append_tid() - Append thread ID to the given string.
113 * Returns -1 on errors, 0 otherwise
142 iph->check = 0; in build_ip_csum()
144 sum = csum_partial(p, iph->ihl << 2, 0); in build_ip_csum()
150 * csum_tcpudp_magic - compute IP pseudo-header checksum
152 * Compute the IPv4 pseudo header checksum. The helper can take a
180 * csum_ipv6_magic - compute IPv6 pseudo-header checksum
182 * Compute the ipv6 pseudo header checksum. The helper can take a
203 s += (__u32)saddr->s6_addr32[i]; in csum_ipv6_magic()
205 s += (__u32)daddr->s6_addr32[i]; in csum_ipv6_magic()
214 * build_udp_v4_csum - compute UDP checksum for UDP over IPv4
216 * Compute the checksum to embed in UDP header, composed of the sum of IP
217 * pseudo-header checksum, UDP header checksum and UDP data checksum
229 sum = csum_partial(udph, ntohs(udph->len), 0); in build_udp_v4_csum()
230 return csum_tcpudp_magic(iph->saddr, iph->daddr, ntohs(udph->len), in build_udp_v4_csum()
235 * build_udp_v6_csum - compute UDP checksum for UDP over IPv6
237 * Compute the checksum to embed in UDP header, composed of the sum of IPv6
238 * pseudo-header checksum, UDP header checksum and UDP data checksum
249 sum = csum_partial(udph, ntohs(udph->len), 0); in build_udp_v6_csum()
250 return csum_ipv6_magic(&ip6h->saddr, &ip6h->daddr, ntohs(udph->len), in build_udp_v6_csum()