912: ip->ip_dst.s_addr,
913: htons(hw_csum + tlen + off + IPPROTO_TCP));
914: }
1204: bzero(&s, sizeof(s));
1205: s.s6_addr16[5] = htons(0xffff);
1206: bcopy(&ip->ip_src, &s.s6_addr32[3], sizeof(ip->ip_src));
1207: bzero(&d, sizeof(d));
1208: d.s6_addr16[5] = htons(0xffff);
1209: bcopy(&ip->ip_dst, &d.s6_addr32[3], sizeof(ip->ip_dst));
2942: ippseudo.ippseudo_p = IPPROTO_TCP;
2943: ippseudo.ippseudo_len = htons(m->m_pkthdr.len - thoff);
2944: MD5Update(&ctx, (char *)&ippseudo, sizeof(ippseudo));
2950: in6_clearscope(&ip6pseudo.ip6ph_dst);
2951: ip6pseudo.ip6ph_len = htons(m->m_pkthdr.len - thoff);
2952: ip6pseudo.ip6ph_nxt = IPPROTO_TCP;
3693: bzero(&in6p->in6p_laddr, sizeof(in6p->in6p_laddr));
3694: in6p->in6p_laddr.s6_addr16[5] = htons(0xffff);
3695: bcopy(&((struct sockaddr_in *)dst)->sin_addr,
3789: sin6->sin6_port = ((struct sockaddr_in *)src)->sin_port;
3790: sin6->sin6_addr.s6_addr16[5] = htons(0xffff);
3791: bcopy(&((struct sockaddr_in *)src)->sin_addr,
4319: th->th_flags = TH_SYN|TH_ACK;
4320: th->th_win = htons(sc->sc_win);
4321: /* th_sum already 0 */
4441: case AF_INET:
4442: ip->ip_len = htons(tlen - hlen);
4443: th->th_sum = 0;
4447: case AF_INET6:
4448: ip6->ip6_plen = htons(tlen - hlen);
4449: th->th_sum = 0;
4461: case AF_INET:
4462: ip->ip_len = htons(tlen);
4463: ip->ip_ttl = ip_defttl;
4470: ip6->ip6_vfc |= IPV6_VERSION;
4471: ip6->ip6_plen = htons(tlen - hlen);
4472: /* ip6_hlim will be initialized afterwards */