Lines Matching refs:iphdr

147 		next_off = sizeof(struct iphdr) + offsetof(struct iphdr, protocol);  in setup_sock_filter()
149 next_off = offsetof(struct iphdr, protocol); in setup_sock_filter()
281 struct iphdr *iph = buf; in fill_networklayer()
302 payload_len + sizeof(struct iphdr)); in fill_networklayer()
308 iph->check = checksum_fold(buf, sizeof(struct iphdr), 0); in fill_networklayer()
352 fill_networklayer(buf + ETH_HLEN, payload_len + sizeof(struct iphdr), in create_packet()
354 fill_networklayer(buf + ETH_HLEN + sizeof(struct iphdr), in create_packet()
473 struct iphdr *iph = (struct iphdr *)(buf + ETH_HLEN); in recompute_packet()
485 iph->check = checksum_fold(iph, sizeof(struct iphdr), 0); in recompute_packet()
491 iph->check = checksum_fold(iph, sizeof(struct iphdr), 0); in recompute_packet()
658 struct iphdr *iph; in add_ipv4_ts_option()
672 iph = (struct iphdr *)(optpkt + ETH_HLEN); in add_ipv4_ts_option()
676 iph->check = checksum_fold(iph, sizeof(struct iphdr) + optlen, 0); in add_ipv4_ts_option()
698 static void fix_ip4_checksum(struct iphdr *iph) in fix_ip4_checksum()
701 iph->check = checksum_fold(iph, sizeof(struct iphdr), 0); in fix_ip4_checksum()
711 struct iphdr *iph1; in send_flush_id_case()
712 struct iphdr *iph2; in send_flush_id_case()
713 struct iphdr *iph3; in send_flush_id_case()
715 iph1 = (struct iphdr *)(buf1 + ETH_HLEN); in send_flush_id_case()
716 iph2 = (struct iphdr *)(buf2 + ETH_HLEN); in send_flush_id_case()
717 iph3 = (struct iphdr *)(buf3 + ETH_HLEN); in send_flush_id_case()
835 struct iphdr *iph = (struct iphdr *)(buf + ETH_HLEN); in send_fragment4()
852 iph->check = checksum_fold(iph, sizeof(struct iphdr), 0); in send_fragment4()
861 struct iphdr *iph = (struct iphdr *)(buf + ETH_HLEN); in send_changed_ttl()
869 iph->check = checksum_fold(iph, sizeof(struct iphdr), 0); in send_changed_ttl()
878 struct iphdr *iph = (struct iphdr *)(buf + ETH_HLEN); in send_changed_tos()
888 iph->check = checksum_fold(iph, sizeof(struct iphdr), 0); in send_changed_tos()
900 struct iphdr *iph = (struct iphdr *)(buf + ETH_HLEN); in send_changed_ECN()
909 iph->check = checksum_fold(iph, sizeof(struct iphdr), 0); in send_changed_ECN()
1001 struct iphdr *iph = (struct iphdr *)(buffer + ETH_HLEN); in check_recv_pkts()
1041 - sizeof(struct tcphdr) - sizeof(struct iphdr); in check_recv_pkts()
1474 tcp_offset = ETH_HLEN + sizeof(struct iphdr) * 2; in main()
1477 tcp_offset = ETH_HLEN + sizeof(struct iphdr); in main()