Lines Matching refs:hlen
474 int hlen;
480 hlen = sizeof(struct mobhdr);
481 if (m->m_pkthdr.len < sizeof(struct ip) + hlen)
482 hlen -= sizeof(struct in_addr);
483 if (m->m_len < sizeof(struct ip) + hlen)
484 m = m_pullup(m, sizeof(struct ip) + hlen);
494 if (hlen != sizeof(struct mobhdr)) {
499 hlen = sizeof(struct mobhdr) - sizeof(struct in_addr);
501 if (me_in_cksum((uint16_t *)mh, hlen / sizeof(uint16_t)) != 0) {
512 ip->ip_len = htons(m->m_pkthdr.len - hlen);
515 memmove(mtodo(m, hlen), ip, sizeof(struct ip));
516 m_adj(m, hlen);
521 hlen = AF_INET;
522 BPF_MTAP2(ifp, &hlen, sizeof(hlen), m);
559 int error, hlen, plen;
601 hlen = sizeof(struct mobhdr) - sizeof(struct in_addr);
604 hlen = sizeof(struct mobhdr);
613 M_PREPEND(m, hlen, M_NOWAIT);
618 if (m->m_len < sizeof(struct ip) + hlen)
619 m = m_pullup(m, sizeof(struct ip) + hlen);
624 memmove(mtod(m, void *), mtodo(m, hlen), sizeof(struct ip));
630 mh.mob_csum = me_in_cksum((uint16_t *)&mh, hlen / sizeof(uint16_t));
631 bcopy(&mh, mtodo(m, sizeof(struct ip)), hlen);