Lines Matching refs:tcp_header
274 static __always_inline bool tscookie_init(struct tcphdr *tcp_header, in tscookie_init() argument
290 .off = (__u8 *)(tcp_header + 1) - (__u8 *)data, in tscookie_init()
303 if (tcp_header->ece && tcp_header->cwr) in tscookie_init()
514 static __always_inline void tcp_gen_synack(struct tcphdr *tcp_header, in tcp_gen_synack() argument
520 tcp_flag_word(tcp_header) = TCP_FLAG_SYN | TCP_FLAG_ACK; in tcp_gen_synack()
522 tcp_flag_word(tcp_header) |= TCP_FLAG_ECE; in tcp_gen_synack()
523 tcp_header->doff = 5; /* doff is part of tcp_flag_word. */ in tcp_gen_synack()
524 swap(tcp_header->source, tcp_header->dest); in tcp_gen_synack()
525 tcp_header->ack_seq = bpf_htonl(bpf_ntohl(tcp_header->seq) + 1); in tcp_gen_synack()
526 tcp_header->seq = bpf_htonl(cookie); in tcp_gen_synack()
527 tcp_header->window = 0; in tcp_gen_synack()
528 tcp_header->urg_ptr = 0; in tcp_gen_synack()
529 tcp_header->check = 0; /* Calculate checksum later. */ in tcp_gen_synack()
531 tcp_options = (void *)(tcp_header + 1); in tcp_gen_synack()
532 tcp_header->doff += tcp_mkoptions(tcp_options, tsopt, mss, wscale); in tcp_gen_synack()