Lines Matching refs:p
47 icmp_input(struct pbuf *p, struct netif *inp)
58 type = ((u8_t *)p->payload)[0];
64 if (p->tot_len < sizeof(struct icmp_echo_hdr)) {
67 pbuf_free(p);
71 iecho = p->payload;
72 iphdr = (struct ip_hdr *)((u8_t *)p->payload - IP_HLEN);
73 if (inet_chksum_pbuf(p) != 0) {
74 LWIP_DEBUGF(ICMP_DEBUG, ("icmp_input: checksum failed for received ICMP echo (%"X16_F")\n", inet_chksum_pseudo(p, &(iphdr->src), &(iphdr->dest), IP_PROTO_ICMP, p->tot_len)));
78 LWIP_DEBUGF(ICMP_DEBUG, ("icmp: p->len %"S16_F" p->tot_len %"S16_F"\n", p->len, p->tot_len));
89 LWIP_DEBUGF(ICMP_DEBUG, ("icmp_input: checksum failed for received ICMP echo (%"X16_F")\n", inet_chksum_pseudo(p, &(iphdr->src), &(iphdr->dest), IP_PROTO_ICMP, p->tot_len)));
92 /* LWIP_DEBUGF("icmp: p->len %"U16_F" p->tot_len %"U16_F"\n", p->len, p->tot_len);*/
93 ip_output_if (p, &(iphdr->src), IP_HDRINCL,
102 pbuf_free(p);
106 icmp_dest_unreach(struct pbuf *p, enum icmp_dur_type t)
117 pbuf_free(p);
123 iphdr = p->payload;
129 SMEMCPY((u8_t *)q->payload + 8, p->payload, IP_HLEN + 8);
142 icmp_time_exceeded(struct pbuf *p, enum icmp_te_type t)
155 pbuf_free(p);
161 iphdr = p->payload;
168 SMEMCPY((u8_t *)q->payload + 8, (u8_t *)p->payload, IP_HLEN + 8);