Lines Matching refs:plen
79 hnd_frame_proto(uint8 *p, int plen, frame_proto_t *fp) in hnd_frame_proto() argument
88 if (p == NULL || plen <= 0) { in hnd_frame_proto()
92 if (plen < (int)sizeof(*eh)) { in hnd_frame_proto()
101 fp->l2_len = (uint16)plen; in hnd_frame_proto()
103 if (plen < (int)sizeof(*sh)) { in hnd_frame_proto()
111 if ((plen -= sizeof(struct dot3_mac_llc_snap_header)) <= 0) { in hnd_frame_proto()
119 if ((plen -= sizeof(struct dot3_mac_llc_snapvlan_header)) <= 0) { in hnd_frame_proto()
133 if ((plen -= ETHERVLAN_HDR_LEN) <= 0) { in hnd_frame_proto()
140 if ((plen -= ETHER_HDR_LEN) <= 0) { in hnd_frame_proto()
147 fp->l3_len = (uint16)plen; in hnd_frame_proto()
150 if ((plen -= ARP_DATA_LEN) < 0) { in hnd_frame_proto()
163 if ((plen -= len) <= 0) { in hnd_frame_proto()
181 if ((plen -= IPV6_MIN_HLEN) <= 0) { in hnd_frame_proto()
191 int32 exth_len = ipv6_exthdr_len_check(p, plen, &proto); in hnd_frame_proto()
192 if (exth_len < 0 || ((plen -= exth_len) <= 0)) in hnd_frame_proto()
207 if ((plen -= EAPOL_HDR_LEN) <= 0) { in hnd_frame_proto()
230 fp->l4_len = (uint16)plen; in hnd_frame_proto()
234 if ((plen -= sizeof(struct bcmicmp_hdr)) < 0) { in hnd_frame_proto()
240 if ((plen -= IGMP_HLEN) < 0) { in hnd_frame_proto()
246 if ((plen -= sizeof(struct bcmtcp_hdr)) < 0) { in hnd_frame_proto()
252 if ((plen -= sizeof(struct bcmudp_hdr)) < 0) { in hnd_frame_proto()
258 if ((plen -= sizeof(struct icmp6_hdr)) < 0) { in hnd_frame_proto()