Home
last modified time | relevance | path

Searched refs:tot_len (Results 1 - 25 of 104) sorted by relevance

12345

/third_party/lwip/src/apps/snmp/
H A Dsnmp_traps.c178 u16_t i, tot_len; in snmp_send_trap() local
205 tot_len = snmp_trap_varbind_sum(&trap_msg, varbinds); in snmp_send_trap()
206 tot_len = snmp_trap_header_sum(&trap_msg, tot_len); in snmp_send_trap()
209 p = pbuf_alloc(PBUF_TRANSPORT, tot_len, PBUF_RAM); in snmp_send_trap()
212 snmp_pbuf_stream_init(&pbuf_stream, p, 0, tot_len); in snmp_send_trap()
283 u16_t tot_len; in snmp_trap_varbind_sum() local
286 tot_len = 0; in snmp_trap_varbind_sum()
292 tot_len += 1 + len.vb_len_len + len.vb_value_len; in snmp_trap_varbind_sum()
298 trap->vbseqlen = tot_len; in snmp_trap_varbind_sum()
316 u16_t tot_len; snmp_trap_header_sum() local
[all...]
/third_party/lwip/src/core/
H A Dpbuf.c28 * The last pbuf of a packet has a ->tot_len field that equals the
34 * loop end condition (tot_len == p->len), NOT (next == NULL).
179 pbuf_init_alloced_pbuf(struct pbuf *p, void *payload, u16_t tot_len, u16_t len, pbuf_type type, u8_t flags) in pbuf_init_alloced_pbuf() argument
183 p->tot_len = tot_len; in pbuf_init_alloced_pbuf()
396 * @note If the pbuf is ROM/REF, only the ->tot_len and ->len fields are adjusted.
411 if (new_len >= p->tot_len) { in pbuf_realloc()
416 /* the pbuf chain grows by (new_len - p->tot_len) bytes in pbuf_realloc()
418 shrink = (u16_t)(p->tot_len - new_len); in pbuf_realloc()
428 q->tot_len in pbuf_realloc()
[all...]
H A Dudp.c232 ("udp_input: short UDP datagram (%"U16_F" bytes) discarded\n", p->tot_len));
245 LWIP_DEBUGF(UDP_DEBUG, ("udp_input: received datagram of length %"U16_F"\n", p->tot_len));
359 chklen = p->tot_len;
367 p->tot_len, chklen,
375 if (ip_chksum_pseudo(p, IP_PROTO_UDP, p->tot_len,
802 if ((u16_t)(p->tot_len + UDP_HLEN) < p->tot_len) {
814 if (p->tot_len != 0) {
843 LWIP_DEBUGF(UDP_DEBUG, ("udp_send: sending datagram of length %"U16_F"\n", q->tot_len));
849 LWIP_DEBUGF(UDP_DEBUG, ("udp_send: UDP LITE packet length %"U16_F"\n", q->tot_len));
[all...]
H A Dtcp_out.c188 LWIP_ASSERT("p->tot_len >= optlen", p->tot_len >= optlen); in tcp_create_segment()
189 seg->len = p->tot_len - optlen; in tcp_create_segment()
282 p->len = p->tot_len = length; in tcp_pbuf_prealloc()
725 /* Bump tot_len of whole chain, len of tail */ in tcp_write()
727 p->tot_len += oversize_used; in tcp_write()
751 last_unsent->len += concat_p->tot_len; in tcp_write()
757 p->tot_len += extendlen; in tcp_write()
759 p->tot_len += extendlen; in tcp_write()
897 offset = useg->p->tot_len in tcp_split_unsent_seg()
[all...]
H A Dtcp_in.c150 LWIP_DEBUGF(TCP_INPUT_DEBUG, ("tcp_input: short packet (%"U16_F" bytes) discarded\n", p->tot_len));
165 u16_t chksum = ip_chksum_pseudo(p, IP_PROTO_TCP, p->tot_len,
179 if ((hdrlen_bytes < TCP_HLEN) || (hdrlen_bytes > p->tot_len)) {
207 options in the next pbuf (adjusting p->tot_len) */
222 adjust p->tot_len to keep it consistent with the changed p->next */
224 p->tot_len = (u16_t)(p->tot_len - opt2len);
227 LWIP_ASSERT("p->tot_len == p->next->tot_len", p->tot_len
[all...]
/third_party/lwip/test/unit/core/
H A Dtest_pbuf.c90 p2->len = p2->tot_len = 0; in START_TEST()
96 p3 = pbuf_alloc(PBUF_RAW, p1->tot_len, PBUF_POOL); in START_TEST()
116 fail_unless(p->tot_len == 1); in START_TEST()
155 fail_unless(p1->tot_len == TESTBUFSIZE_1); in START_TEST()
156 fail_unless(rest2->tot_len == (u16_t)((TESTBUFSIZE_2+TESTBUFSIZE_3) & 0xFFFF)); in START_TEST()
158 fail_unless(rest2->tot_len == TESTBUFSIZE_2); in START_TEST()
159 fail_unless(rest3->tot_len == TESTBUFSIZE_3); in START_TEST()
188 fail_if(p->tot_len == p->len); in START_TEST()
240 fail_if(p->tot_len == p->len); in START_TEST()
/third_party/wpa_supplicant/wpa_supplicant-2.9/src/ap/
H A Ddhcp_snoop.c42 u16 tot_len; in handle_dhcp() local
49 tot_len = ntohs(b->iph.tot_len); in handle_dhcp()
50 if (tot_len > (unsigned int) (len - ETH_HLEN)) in handle_dhcp()
57 end = (const u8 *) b + tot_len; in handle_dhcp()
H A Dfils_hlp.c264 iph->tot_len = htons(sizeof(*iph) + sizeof(*udph) + (end - pos)); in fils_dhcp_handler()
514 u16 tot_len; in fils_process_hlp_ip() local
524 tot_len = ntohs(iph->tot_len); in fils_process_hlp_ip()
525 if (tot_len > len) in fils_process_hlp_ip()
/third_party/lwip/src/netif/
H A Dlowpan6_ble.c246 p_frag = pbuf_alloc(PBUF_RAW, p->tot_len, PBUF_RAM); in rfc7668_compress()
251 LWIP_ASSERT("this needs a pbuf in one piece", p_frag->len == p_frag->tot_len); in rfc7668_compress()
266 remaining_len = p->tot_len; in rfc7668_compress()
272 p_frag->len = p_frag->tot_len = remaining_len + lowpan6_header_len; in rfc7668_compress()
275 MIB2_STATS_NETIF_ADD(netif, ifoutoctets, p_frag->tot_len); in rfc7668_compress()
351 MIB2_STATS_NETIF_ADD(netif, ifinoctets, p->tot_len); in rfc7668_input()
H A Dzepif.c146 if (zep->len != p->tot_len - sizeof(struct zep_hdr)) { in zepif_udp_recv()
155 pbuf_realloc(p, p->tot_len - 2); in zepif_udp_recv()
178 if (p->tot_len > ZEP_MAX_DATA_LEN) { in zepif_linkoutput()
186 q = pbuf_alloc(PBUF_TRANSPORT, sizeof(struct zep_hdr) + p->tot_len, PBUF_RAM); in zepif_linkoutput()
202 zep->len = (u8_t)p->tot_len; in zepif_linkoutput()
204 err = pbuf_copy_partial_pbuf(q, p, p->tot_len, sizeof(struct zep_hdr)); in zepif_linkoutput()
H A Dlowpan6.c388 LWIP_ASSERT("this needs a pbuf in one piece", p_frag->len == p_frag->tot_len); in lowpan6_frag()
415 remaining_len = p->tot_len; in lowpan6_frag()
432 buffer[ieee_header_len] = 0xc0 | (((p->tot_len + hidden_header_len) >> 8) & 0x7); in lowpan6_frag()
433 buffer[ieee_header_len + 1] = (p->tot_len + hidden_header_len) & 0xff; in lowpan6_frag()
450 p_frag->len = p_frag->tot_len = ieee_header_len + 4 + frag_len + 2; /* add 2 bytes for crc*/ in lowpan6_frag()
457 MIB2_STATS_NETIF_ADD(netif, ifoutoctets, p_frag->tot_len); in lowpan6_frag()
476 pbuf_copy_partial(p, buffer + ieee_header_len + 5, frag_len, p->tot_len - remaining_len); in lowpan6_frag()
481 p_frag->len = p_frag->tot_len = frag_len + 5 + ieee_header_len + 2; in lowpan6_frag()
488 MIB2_STATS_NETIF_ADD(netif, ifoutoctets, p_frag->tot_len); in lowpan6_frag()
501 p_frag->len = p_frag->tot_len in lowpan6_frag()
[all...]
H A Dethernet.c181 p->tot_len, next_hdr_offset));
198 p->tot_len, next_hdr_offset));
225 p->tot_len, next_hdr_offset));
/third_party/lwip/src/core/ipv4/
H A Dicmp.c101 LWIP_DEBUGF(ICMP_DEBUG, ("icmp_input: short ICMP (%"U16_F" bytes) received\n", p->tot_len)); in icmp_input()
141 if (p->tot_len < sizeof(struct icmp_echo_hdr)) { in icmp_input()
162 u16_t alloc_len = (u16_t)(p->tot_len + hlen); in icmp_input()
163 if (alloc_len < p->tot_len) { in icmp_input()
164 LWIP_DEBUGF(ICMP_DEBUG, ("icmp_input: allocating new pbuf failed (tot_len overflow)\n")); in icmp_input()
355 if (p->tot_len < response_pkt_len) { in icmp_send_response()
356 response_pkt_len = p->tot_len; in icmp_send_response()
H A Dip4.c382 if (netif->mtu && (p->tot_len > netif->mtu)) {
506 if (iphdr_len < p->tot_len) {
511 if ((iphdr_hlen > p->len) || (iphdr_len > p->tot_len) || (iphdr_hlen < IP_HLEN)) {
521 if (iphdr_len > p->tot_len) {
524 iphdr_len, p->tot_len));
680 LWIP_DEBUGF(IP_DEBUG, ("IP packet is a fragment (id=0x%04"X16_F" tot_len=%"U16_F" len=%"U16_F" MF=%"U16_F" offset=%"U16_F"), calling ip4_reass()\n",
681 lwip_ntohs(IPH_ID(iphdr)), p->tot_len, lwip_ntohs(IPH_LEN(iphdr)), (u16_t)!!(IPH_OFFSET(iphdr) & PP_HTONS(IP_MF)), (u16_t)((lwip_ntohs(IPH_OFFSET(iphdr)) & IP_OFFMASK) * 8)));
722 LWIP_DEBUGF(IP_DEBUG, ("ip4_input: p->len %"U16_F" p->tot_len %"U16_F"\n", p->len, p->tot_len));
966 IPH_LEN_SET(iphdr, lwip_htons(p->tot_len));
[all...]
/third_party/lwip/src/netif/ppp/
H A Dpppoe.c214 u16_t tot_len; in pppoe_write() local
234 tot_len = ph->tot_len; in pppoe_write()
244 MIB2_STATS_NETIF_ADD(ppp->netif, ifoutoctets, (u16_t)tot_len); in pppoe_write()
257 u16_t tot_len; in pppoe_netif_output() local
278 tot_len = pb->tot_len; in pppoe_netif_output()
287 MIB2_STATS_NETIF_ADD(ppp->netif, ifoutoctets, tot_len); in pppoe_netif_output()
425 if(pb->tot_len == pb->len) { in pppoe_disc_input()
429 pb->tot_len in pppoe_disc_input()
[all...]
H A Dpppol2tp.c170 u16_t tot_len; in pppol2tp_write() local
187 tot_len = ph->tot_len; in pppol2tp_write()
197 MIB2_STATS_NETIF_ADD(ppp->netif, ifoutoctets, (u16_t)tot_len); in pppol2tp_write()
210 u16_t tot_len; in pppol2tp_netif_output() local
231 tot_len = pb->tot_len; in pppol2tp_netif_output()
240 MIB2_STATS_NETIF_ADD(ppp->netif, ifoutoctets, tot_len); in pppol2tp_netif_output()
526 if (p->tot_len == 0) { in pppol2tp_dispatch_control_packet()
829 LWIP_ASSERT("pb->tot_len in pppol2tp_send_sccrq()
[all...]
H A Dpppos.c223 /* Set nb->tot_len to actual payload length */ in pppos_write()
224 nb->tot_len = p->len; in pppos_write()
273 /* Set nb->tot_len to actual payload length */ in pppos_netif_output()
274 nb->tot_len = pb->tot_len; in pppos_netif_output()
305 PPPDEBUG(LOG_INFO, ("pppos_netif_output[%d]: proto=0x%"X16_F", len = %d\n", ppp->netif->num, protocol, pb->tot_len)); in pppos_netif_output()
307 PPPDEBUG(LOG_WARNING, ("pppos_netif_output[%d]: output failed proto=0x%"X16_F", len = %d\n", ppp->netif->num, protocol, pb->tot_len)); in pppos_netif_output()
541 pppos->in_tail->tot_len = pppos->in_tail->len; in pppos_input()
546 pppos->in_tail->tot_len = pppos->in_tail->len; in pppos_input()
551 pbuf_realloc(pppos->in_head, pppos->in_head->tot_len in pppos_input()
[all...]
H A Dmppe.c204 np = pbuf_alloc(PBUF_RAW, MPPE_OVHD + sizeof(protocol) + (*pb)->tot_len, PBUF_RAM); in mppe_compress()
254 if (n->tot_len == n->len) { in mppe_compress()
390 if (n->tot_len == n->len) { in mppe_decompress()
/third_party/lwip/test/unit/tcp/
H A Dtcp_helper.c76 IPH_LEN_SET(iphdr, htons(p->tot_len)); in tcp_create_segment_wnd()
103 IP_PROTO_TCP, p->tot_len, src_ip, dst_ip); in tcp_create_segment_wnd()
200 EXPECT_RET(counters->recved_bytes + p->tot_len <= counters->expected_data_len); in test_tcp_counters_check_rxdata()
209 EXPECT(received == counters->recved_bytes + p->tot_len); in test_tcp_counters_check_rxdata()
224 counters->recved_bytes += p->tot_len; in test_tcp_counters_recv()
227 counters->recved_bytes_after_close += p->tot_len; in test_tcp_counters_recv()
282 txcounters->num_tx_bytes += p->tot_len; in test_tcp_netif_output()
284 struct pbuf *p_copy = pbuf_alloc(PBUF_LINK, p->tot_len, PBUF_RAM); in test_tcp_netif_output()
/third_party/lwip/doc/
H A DNO_SYS_SampleCode.c27 MIB2_STATS_NETIF_ADD(netif, ifoutoctets, p->tot_len); in netif_output()
36 pbuf_copy_partial(p, mac_send_buffer, p->tot_len, 0); in netif_output()
104 MIB2_STATS_NETIF_ADD(netif, ifinoctets, p->tot_len); in main()
/third_party/lwip/src/core/ipv6/
H A Dicmp6.c104 if (ip6_chksum_pseudo(p, IP6_NEXTH_ICMP6, p->tot_len, ip6_current_src_addr(), in icmp6_input()
147 r = pbuf_alloc(PBUF_IP, p->tot_len, PBUF_RAM); in icmp6_input()
188 IP6_NEXTH_ICMP6, r->tot_len, reply_src, ip6_current_src_addr()); in icmp6_input()
394 u16_t datalen = LWIP_MIN(p->tot_len, LWIP_ICMP6_DATASIZE); in icmp6_send_response_with_addrs_and_netif()
428 icmp6hdr->chksum = ip6_chksum_pseudo(q, IP6_NEXTH_ICMP6, q->tot_len, in icmp6_send_response_with_addrs_and_netif()
H A Dip6_frag.c764 LWIP_ASSERT("p->tot_len >= IP6_HLEN", p->tot_len >= IP6_HLEN); in ip6_frag()
765 left = (u16_t)(p->tot_len - IP6_HLEN); in ip6_frag()
780 (rambuf->len == rambuf->tot_len) && (rambuf->next == NULL)); in ip6_frag()
812 p->tot_len = (u16_t)(p->tot_len - poff); in ip6_frag()
/third_party/lwip/src/apps/lwiperf/
H A Dlwiperf.c459 u16_t tot_len; in lwiperf_tcp_recv() local
482 tot_len = p->tot_len; in lwiperf_tcp_recv()
488 if (p->tot_len < sizeof(lwiperf_settings_t)) { in lwiperf_tcp_recv()
523 tcp_recved(tpcb, p->tot_len); in lwiperf_tcp_recv()
555 LWIP_ASSERT("count mismatch", packet_idx == p->tot_len); in lwiperf_tcp_recv()
557 tcp_recved(tpcb, tot_len); in lwiperf_tcp_recv()
/third_party/FreeBSD/sys/dev/usb/net/
H A Dusb_ethernet.c582 ue->ue_rxq.ifq_head->tot_len += len; in uether_rxmbuf()
592 int tot_len = 0; in uether_rxflush() local
599 tot_len += q->len; in uether_rxflush()
601 m->tot_len = tot_len; in uether_rxflush()
/third_party/ffmpeg/libavformat/
H A Drtpdec_h264.c269 int tot_len = len; in ff_h264_handle_frag_packet() local
272 tot_len += sizeof(start_sequence) + nal_header_len; in ff_h264_handle_frag_packet()
273 if ((ret = av_new_packet(pkt, tot_len)) < 0) in ff_h264_handle_frag_packet()

Completed in 18 milliseconds

12345