Lines Matching refs:icmp_packet
782 struct icmp_packet_rr *icmp_packet;
790 icmp_packet = (struct icmp_packet_rr *)skb->data;
794 if (icmp_packet->msg_type != ECHO_REQUEST) {
795 bat_socket_receive_packet(icmp_packet, icmp_len);
806 icmp_packet->orig));
825 icmp_packet = (struct icmp_packet_rr *)skb->data;
830 memcpy(icmp_packet->dst, icmp_packet->orig, ETH_ALEN);
831 memcpy(icmp_packet->orig,
833 icmp_packet->msg_type = ECHO_REPLY;
834 icmp_packet->ttl = TTL;
849 struct icmp_packet *icmp_packet;
857 icmp_packet = (struct icmp_packet *)skb->data;
861 if (icmp_packet->msg_type != ECHO_REQUEST) {
863 "%pM: ttl exceeded\n", icmp_packet->orig,
864 icmp_packet->dst);
874 hash_find(orig_hash, icmp_packet->orig));
892 icmp_packet = (struct icmp_packet *) skb->data;
897 memcpy(icmp_packet->dst, icmp_packet->orig, ETH_ALEN);
898 memcpy(icmp_packet->orig,
900 icmp_packet->msg_type = TTL_EXCEEDED;
901 icmp_packet->ttl = TTL;
915 struct icmp_packet_rr *icmp_packet;
920 int hdr_size = sizeof(struct icmp_packet);
949 icmp_packet = (struct icmp_packet_rr *)skb->data;
953 (icmp_packet->rr_cur < BAT_RR_LEN)) {
954 memcpy(&(icmp_packet->rr[icmp_packet->rr_cur]),
956 icmp_packet->rr_cur++;
960 if (is_my_mac(icmp_packet->dst))
964 if (icmp_packet->ttl < 2)
972 hash_find(orig_hash, icmp_packet->dst));
989 icmp_packet = (struct icmp_packet_rr *)skb->data;
995 icmp_packet->ttl--;