Lines Matching refs:ehp
1474 struct bpf_hdr_ext *ehp; in bpfread() local
1479 ehp = (struct bpf_hdr_ext *)(void *)p; in bpfread()
1480 if ((flowid = ehp->bh_flowid) != 0) { in bpfread()
1481 if (ehp->bh_flags & BPF_HDR_EXT_FLAGS_TCP) { in bpfread()
1482 ehp->bh_flags &= ~BPF_HDR_EXT_FLAGS_TCP; in bpfread()
1485 } else if (ehp->bh_flags == BPF_HDR_EXT_FLAGS_UDP) { in bpfread()
1486 ehp->bh_flags &= ~BPF_HDR_EXT_FLAGS_UDP; in bpfread()
1491 ehp->bh_pid = soprocinfo.spi_pid; in bpfread()
1492 strbufcpy(ehp->bh_comm, in bpfread()
1495 ehp->bh_flowid = 0; in bpfread()
1498 if ((flags & BPF_FINALIZE_PKTAP) != 0 && ehp->bh_complen == 0) { in bpfread()
1502 (p + BPF_WORDALIGN(ehp->bh_hdrlen)); in bpfread()
1504 bpf_finalize_pktap((struct bpf_hdr *) ehp, in bpfread()
1507 p += BPF_WORDALIGN(ehp->bh_hdrlen + ehp->bh_caplen); in bpfread()
4055 struct bpf_hdr_ext *ehp; in catchpacket() local
4134 ehp = (struct bpf_hdr_ext *)(void *)(d->bd_sbuf + curlen); in catchpacket()
4135 memset(ehp, 0, sizeof(*ehp)); in catchpacket()
4136 ehp->bh_tstamp.tv_sec = (int)tv.tv_sec; in catchpacket()
4137 ehp->bh_tstamp.tv_usec = tv.tv_usec; in catchpacket()
4139 ehp->bh_datalen = (bpf_u_int32)pkt->bpfp_total_length; in catchpacket()
4140 ehp->bh_hdrlen = (u_short)hdrlen; in catchpacket()
4141 caplen = ehp->bh_caplen = totlen - hdrlen; in catchpacket()
4142 payload = (u_char *)ehp + hdrlen; in catchpacket()
4145 ehp->bh_flags |= BPF_HDR_EXT_FLAGS_DIR_OUT; in catchpacket()
4147 ehp->bh_flags |= BPF_HDR_EXT_FLAGS_DIR_IN; in catchpacket()
4154 ehp->bh_pktflags |= BPF_PKTFLAGS_ULPN; in catchpacket()
4163 ehp->bh_flowid = m->m_pkthdr.pkt_flowid; in catchpacket()
4165 ehp->bh_flags |= BPF_HDR_EXT_FLAGS_TCP; in catchpacket()
4167 ehp->bh_flags |= BPF_HDR_EXT_FLAGS_UDP; in catchpacket()
4170 ehp->bh_svc = so_svc2tc(m->m_pkthdr.pkt_svc); in catchpacket()
4172 ehp->bh_pktflags |= BPF_PKTFLAGS_TCP_REXMT; in catchpacket()
4175 ehp->bh_pktflags |= BPF_PKTFLAGS_START_SEQ; in catchpacket()
4178 ehp->bh_pktflags |= BPF_PKTFLAGS_LAST_PKT; in catchpacket()
4181 ehp->bh_unsent_bytes = in catchpacket()
4183 ehp->bh_unsent_snd = in catchpacket()
4186 ehp->bh_comp_gencnt = m->m_pkthdr.comp_gencnt; in catchpacket()
4189 ehp->bh_pktflags |= BPF_PKTFLAGS_WAKE_PKT; in catchpacket()
4198 ehp->bh_pktflags |= BPF_PKTFLAGS_ULPN; in catchpacket()
4206 ehp->bh_svc = so_svc2tc((mbuf_svc_class_t)kern_packet_get_service_class(kern_pkt)); in catchpacket()
4208 ehp->bh_pktflags |= BPF_PKTFLAGS_TCP_REXMT; in catchpacket()
4211 ehp->bh_pktflags |= BPF_PKTFLAGS_LAST_PKT; in catchpacket()
4213 kern_packet_get_compression_generation_count(kern_pkt, &ehp->bh_comp_gencnt); in catchpacket()
4216 ehp->bh_pktflags |= BPF_PKTFLAGS_WAKE_PKT; in catchpacket()
4219 ehp->bh_trace_tag = kern_packet_get_trace_tag(kern_pkt); in catchpacket()
4221 ehp->bh_flowid = flowid; in catchpacket()
4261 ehp->bh_complen = common_prefix_size; in catchpacket()
4263 ehp->bh_caplen -= common_prefix_size; in catchpacket()