Lines Matching refs:wp
179 u_char *cp, *wp, *hp;
186 hp = wp = MBUF_CTOP(mwp);
188 *wp++ = *cp++ = orglen >> 8;
189 *wp++ = *cp++ = orglen & 0377;
196 len = compress(state, bufp + 2, wp, orglen);
201 wp += len;
204 memcpy(wp, bufp + 2, orglen);
205 wp += orglen;
209 *wp++ = fcs & 0377;
210 *wp++ = fcs >> 8;
211 mwp->m_len = wp - MBUF_CTOP(mwp);
222 struct mbuf *wp;
226 wp = m_get(MAX_MRU + 2, MB_CCPIN);
229 pp = bufp = MBUF_CTOP(wp);
243 m_freem(wp);
251 m_freem(wp);
262 fcs = hdlc_Fcs(bufp, wp->m_len = pp - bufp);
264 wp->m_offset += 2; /* skip length */
265 wp->m_len -= 4; /* skip length & CRC */
266 pp = MBUF_CTOP(wp);
269 wp->m_offset++;
270 wp->m_len--;
272 wp->m_offset += 2;
273 wp->m_len -= 2;
277 return wp;
285 m_freem(wp);