| /tools/testing/selftests/bpf/progs/ |
| A D | cgroup_tcp_skb.c | 48 static int egress_accept(struct tcphdr *tcph) in egress_accept() 61 static int ingress_accept(struct tcphdr *tcph) in ingress_accept() 84 static int egress_connect(struct tcphdr *tcph) in egress_connect() 208 struct tcphdr tcph; in server_egress() 231 struct tcphdr tcph; in server_ingress() 254 struct tcphdr tcph; in server_egress_srv() 277 struct tcphdr tcph; in server_ingress_srv() 300 struct tcphdr tcph; in client_egress_srv() 323 struct tcphdr tcph; in client_ingress_srv() 346 struct tcphdr tcph; in client_egress() [all …]
|
| A D | test_parse_tcp_hdr_opt_dynptr.c | 77 __u8 buffer[sizeof(struct tcphdr)] = {}; in xdp_ingress_v6() 79 struct tcphdr *tcp_hdr; in xdp_ingress_v6() 94 tcp_hdr_opt_len = (tcp_hdr->doff * 4) - sizeof(struct tcphdr); in xdp_ingress_v6() 100 off += sizeof(struct tcphdr); in xdp_ingress_v6()
|
| A D | test_parse_tcp_hdr_opt.c | 88 struct tcphdr *tcp_hdr; in xdp_ingress_v6() 93 tcp_hdr = (struct tcphdr *)(data + tcp_offset); in xdp_ingress_v6() 97 tcp_hdr_opt_len = (tcp_hdr->doff * 4) - sizeof(struct tcphdr); in xdp_ingress_v6() 102 opt_state.byte_offset = sizeof(struct tcphdr) + tcp_offset; in xdp_ingress_v6()
|
| A D | test_tcpbpf_kern.c | 34 char header[sizeof(struct ipv6hdr) + sizeof(struct tcphdr)]; in bpf_testcb() 36 struct tcphdr *thdr; in bpf_testcb() 108 sizeof(struct tcphdr))); in bpf_testcb() 112 thdr = (struct tcphdr *)(header + offset); in bpf_testcb()
|
| A D | test_pkt_access.c | 89 struct tcphdr *tcp = NULL; in test_pkt_write_access_subprog() 108 struct tcphdr *tcp = NULL; in test_pkt_access() 122 tcp = (struct tcphdr *)((void *)(iph) + ihl_len); in test_pkt_access() 130 tcp = (struct tcphdr *)((void *)(ip6h) + ihl_len); in test_pkt_access()
|
| A D | test_assign_reuse.c | 20 struct tcphdr tcp; 81 maybe_assign_tcp(struct __sk_buff *skb, struct tcphdr *th) in maybe_assign_tcp() 124 return maybe_assign_tcp(skb, (struct tcphdr *)(iph + 1)); in tc_main() 136 return maybe_assign_tcp(skb, (struct tcphdr *)(ip6h + 1)); in tc_main()
|
| A D | cgroup_skb_sk_lookup_kern.c | 31 const struct tcphdr *tcph) in set_tuple() 41 const struct tcphdr *tcph) in is_allowed_peer_cg() 70 struct tcphdr tcph; in ingress_lookup()
|
| A D | test_migrate_reuseport.c | 50 struct tcphdr *tcp = NULL; in drop_ack() 65 tcp = (struct tcphdr *)((void *)ip + ip->ihl * 4); in drop_ack() 77 tcp = (struct tcphdr *)(ipv6 + 1); in drop_ack()
|
| A D | test_btf_skc_cls_ingress.c | 24 struct tcphdr *th, struct tcp_sock *tp, in test_syncookie_helper() 74 struct tcphdr *th; in handle_ip_tcp() 86 th = (struct tcphdr *)(ip4h + 1); in handle_ip_tcp() 103 th = (struct tcphdr *)(ip6h + 1); in handle_ip_tcp()
|
| A D | skb_pkt_end.c | 13 #define ETH_IPV4_TCP_SIZE (14 + sizeof(struct iphdr) + sizeof(struct tcphdr)) 34 struct tcphdr *tcp; in main_prog()
|
| A D | test_misc_tcp_hdr_options.c | 36 struct tcphdr th; in __check_active_hdr_in() 43 struct tcphdr *pth; in __check_active_hdr_in() 111 pth = (struct tcphdr *)(&hdr.ip6 + 1); in __check_active_hdr_in() 132 struct tcphdr *th; in check_active_hdr_in() 175 struct tcphdr *th; in write_active_opt()
|
| A D | test_tc_edt.c | 65 static inline int handle_tcp(struct __sk_buff *skb, struct tcphdr *tcp) in handle_tcp() 97 return handle_tcp(skb, (struct tcphdr *)(((void *)iph) + ihl)); in handle_ipv4()
|
| A D | test_xdp_dynptr.c | 21 #define tcphdr_sz sizeof(struct tcphdr) 52 struct tcphdr *th; in get_dport() 57 th = (struct tcphdr *)trans_data; in get_dport()
|
| A D | xdpwall.c | 173 static __always_inline bool tcphdr_only_contains_flag(struct tcphdr *tcp, in tcphdr_only_contains_flag() 181 struct tcphdr *tcp) { in set_tcp_flags() 193 struct tcphdr *tcp = transport_hdr; in parse_tcp()
|
| A D | test_tcp_custom_syncookie.c | 63 struct tcphdr *tcp; 98 ctx->tcp = (struct tcphdr *)(ctx->ipv4 + 1); in tcp_load_headers() 112 ctx->tcp = (struct tcphdr *)(ctx->ipv6 + 1); in tcp_load_headers() 146 ctx->tcp = (struct tcphdr *)(ctx->ipv4 + 1); in tcp_reload_headers() 150 ctx->tcp = (struct tcphdr *)(ctx->ipv6 + 1); in tcp_reload_headers()
|
| A D | verifier_netfilter_ctx.c | 96 const struct tcphdr *th; in with_valid_ctx_access_test6()
|
| A D | test_xdp.c | 50 struct tcphdr *th; in get_dport() 55 th = (struct tcphdr *)trans_data; in get_dport()
|
| A D | test_xdp_loop.c | 46 struct tcphdr *th; in get_dport() 51 th = (struct tcphdr *)trans_data; in get_dport()
|
| A D | fexit_bpf2bpf.c | 162 struct tcphdr *tcp; in new_test_pkt_write_access_subprog()
|
| /tools/testing/selftests/net/ |
| A D | gro.c | 270 iph->tot_len = htons(sizeof(struct tcphdr) + in fill_networklayer() 284 struct tcphdr *tcph = buf; in fill_transportlayer() 329 struct tcphdr *tcph; in send_flags() 404 struct tcphdr *tcphdr = (struct tcphdr *)(buf + tcp_offset); in recompute_packet() local 412 tcphdr->doff = tcphdr->doff + (extlen / 4); in recompute_packet() 413 tcphdr->check = 0; in recompute_packet() 414 tcphdr->check = tcp_checksum(tcphdr, PAYLOAD_LEN + extlen); in recompute_packet() 498 struct tcphdr *tcph = (struct tcphdr *)(buf + tcp_offset); in send_changed_checksum() 513 struct tcphdr *tcph = (struct tcphdr *)(buf + tcp_offset); in send_changed_seq() 618 sizeof(struct tcphdr) + PAYLOAD_LEN); in add_ipv6_exthdr() [all …]
|
| /tools/testing/selftests/net/lib/ |
| A D | csum.c | 125 #define MAX_HEADER_LEN (sizeof(struct ipv6hdr) + ENC_HEADER_LEN + sizeof(struct tcphdr)) 258 struct tcphdr *th = _th; in build_packet_tcp() 287 sizeof(struct tcphdr) + in build_packet_udp_encap() 314 tlen = sizeof(struct tcphdr) + cfg_payload_len; in build_packet() 434 vh.csum_offset = __builtin_offsetof(struct tcphdr, check); in send_packet() 435 vh.hdr_len = vh.csum_start + sizeof(struct tcphdr); in send_packet() 517 const int off_dport = offsetof(struct tcphdr, dest); /* same for udp */ in recv_prepare_packet_filter() 618 struct tcphdr *tcph = th; in recv_verify_packet_tcp()
|
| /tools/testing/selftests/bpf/prog_tests/ |
| A D | flow_dissector.c | 21 struct tcphdr tcp; 28 struct tcphdr tcp; 36 struct tcphdr tcp; 42 struct tcphdr tcp; 54 struct tcphdr tcp; 64 struct tcphdr tcp; 77 struct tcphdr tcp;
|
| /tools/testing/selftests/bpf/ |
| A D | network_helpers.h | 49 struct tcphdr tcp; 57 struct tcphdr tcp;
|
| A D | test_tcp_hdr_options.h | 96 static inline unsigned int tcp_hdrlen(const struct tcphdr *th) in tcp_hdrlen()
|
| /tools/include/uapi/linux/ |
| A D | tcp.h | 25 struct tcphdr { struct 66 struct tcphdr hdr; argument
|