Lines Matching refs:tcphdr

69 #define TOTAL_HDR_LEN (ETH_HLEN + sizeof(struct ipv6hdr) + sizeof(struct tcphdr))
70 #define MSS (4096 - sizeof(struct tcphdr) - sizeof(struct ipv6hdr))
71 #define MAX_PAYLOAD (IP_MAXPACKET - sizeof(struct tcphdr) - sizeof(struct ipv6hdr))
73 #define MAX_HDR_LEN (ETH_HLEN + sizeof(struct ipv6hdr) + sizeof(struct tcphdr))
104 const int dport_off = tcp_offset + offsetof(struct tcphdr, dest); in setup_sock_filter()
187 ph6.payload_len = htons(sizeof(struct tcphdr) + payload_len); in tcp_checksum()
196 ph4.payload_len = htons(sizeof(struct tcphdr) + payload_len); in tcp_checksum()
201 return checksum_fold(buf, sizeof(struct tcphdr) + payload_len, sum); in tcp_checksum()
230 ip6h->payload_len = htons(sizeof(struct tcphdr) + payload_len); in fill_networklayer()
244 iph->tot_len = htons(sizeof(struct tcphdr) + in fill_networklayer()
258 struct tcphdr *tcph = buf; in fill_transportlayer()
303 struct tcphdr *tcph; in send_flags()
311 tcph = (struct tcphdr *)(flag_buf + tcp_offset); in send_flags()
378 struct tcphdr *tcphdr = (struct tcphdr *)(buf + tcp_offset); in recompute_packet() local
386 tcphdr->doff = tcphdr->doff + (extlen / 4); in recompute_packet()
387 tcphdr->check = 0; in recompute_packet()
388 tcphdr->check = tcp_checksum(tcphdr, PAYLOAD_LEN + extlen); in recompute_packet()
472 struct tcphdr *tcph = (struct tcphdr *)(buf + tcp_offset); in send_changed_checksum()
487 struct tcphdr *tcph = (struct tcphdr *)(buf + tcp_offset); in send_changed_seq()
570 sizeof(struct tcphdr) + PAYLOAD_LEN); in add_ipv4_ts_option()
710 sizeof(struct tcphdr) + PAYLOAD_LEN); in send_fragment6()
748 struct tcphdr *tcph; in check_recv_pkts()
772 tcph = (struct tcphdr *)(buffer + tcp_offset + ip_ext_len); in check_recv_pkts()
785 - sizeof(struct tcphdr) - sizeof(struct iphdr); in check_recv_pkts()
1088 total_hdr_len = tcp_offset + sizeof(struct tcphdr); in main()