Home
last modified time | relevance | path

Searched refs:tcphdr (Results 1 – 25 of 50) sorted by relevance

12

/xnu-11215.81.4/bsd/netinet/
H A Dtcp_newreno.c80 void tcp_newreno_congestion_avd(struct tcpcb *tp, struct tcphdr *th);
81 void tcp_newreno_ack_rcvd(struct tcpcb *tp, struct tcphdr *th);
83 void tcp_newreno_post_fr(struct tcpcb *tp, struct tcphdr *th);
86 int tcp_newreno_delay_ack(struct tcpcb *tp, struct tcphdr *th);
140 tcp_newreno_congestion_avd(struct tcpcb *tp, struct tcphdr *th) in tcp_newreno_congestion_avd()
159 tcp_newreno_ack_rcvd(struct tcpcb *tp, struct tcphdr *th) in tcp_newreno_ack_rcvd()
219 tcp_newreno_post_fr(struct tcpcb *tp, struct tcphdr *th) in tcp_newreno_post_fr()
312 tcp_newreno_delay_ack(struct tcpcb *tp, struct tcphdr *th) in tcp_newreno_delay_ack()
H A Dtcp_cc.h198 void (*congestion_avd) (struct tcpcb *tp, struct tcphdr *th);
201 void (*ack_rcvd) (struct tcpcb *tp, struct tcphdr *th);
207 void (*post_fr) (struct tcpcb *tp, struct tcphdr *th);
216 int (*delay_ack)(struct tcpcb *tp, struct tcphdr *th);
219 …void (*process_ecn) (struct tcpcb *tp, struct tcphdr *th, uint32_t new_bytes_marked, uint32_t pack…
258 void (*data_rcvd) (struct tcpcb *tp, struct tcphdr *th,
276 extern int tcp_cc_delay_ack(struct tcpcb *tp, struct tcphdr *th);
H A Dtcp_cubic.c44 static void tcp_cubic_congestion_avd(struct tcpcb *tp, struct tcphdr *th);
45 static void tcp_cubic_ack_rcvd(struct tcpcb *tp, struct tcphdr *th);
47 static void tcp_cubic_post_fr(struct tcpcb *tp, struct tcphdr *th);
49 static int tcp_cubic_delay_ack(struct tcpcb *tp, struct tcphdr *th);
236 tcp_cubic_tcpwin(struct tcpcb *tp, struct tcphdr *th) in tcp_cubic_tcpwin()
283 tcp_cubic_congestion_avd(struct tcpcb *tp, struct tcphdr *th) in tcp_cubic_congestion_avd()
357 tcp_cubic_ack_rcvd(struct tcpcb *tp, struct tcphdr *th) in tcp_cubic_ack_rcvd()
480 tcp_cubic_post_fr(struct tcpcb *tp, struct tcphdr *th) in tcp_cubic_post_fr()
580 tcp_cubic_delay_ack(struct tcpcb *tp, struct tcphdr *th) in tcp_cubic_delay_ack()
H A Dtcp_ledbat.c56 void tcp_ledbat_congestion_avd(struct tcpcb *tp, struct tcphdr *th);
57 void tcp_ledbat_ack_rcvd(struct tcpcb *tp, struct tcphdr *th);
60 void tcp_ledbat_post_fr(struct tcpcb *tp, struct tcphdr *th);
63 static int tcp_ledbat_delay_ack(struct tcpcb *tp, struct tcphdr *th);
194 tcp_ledbat_congestion_avd(struct tcpcb *tp, struct tcphdr *th) in tcp_ledbat_congestion_avd()
377 tcp_ledbat_ack_rcvd(struct tcpcb *tp, struct tcphdr *th) in tcp_ledbat_ack_rcvd()
459 tcp_ledbat_post_fr(struct tcpcb *tp, struct tcphdr *th) in tcp_ledbat_post_fr()
538 tcp_ledbat_delay_ack(struct tcpcb *tp, struct tcphdr *th) in tcp_ledbat_delay_ack()
H A Dtcp_prague.c34 static void tcp_prague_ack_rcvd(struct tcpcb *tp, struct tcphdr *th);
36 static void tcp_prague_post_fr(struct tcpcb *tp, struct tcphdr *th);
38 static int tcp_prague_delay_ack(struct tcpcb *tp, struct tcphdr *th);
41 static void tcp_prague_process_ecn(struct tcpcb *tp, struct tcphdr *th, uint32_t new_bytes_marked,
157 reno_friendly_win(struct tcpcb *tp, struct tcphdr *th) in reno_friendly_win()
195 tcp_cubic_ack_ca(struct tcpcb *tp, struct tcphdr *th, uint32_t acked) in tcp_cubic_ack_ca()
246 tcp_prague_ack_rcvd(struct tcpcb *tp, struct tcphdr *th) in tcp_prague_ack_rcvd()
327 tcp_prague_post_fr(struct tcpcb *tp, __unused struct tcphdr *th) in tcp_prague_post_fr()
517 tcp_prague_process_ecn(struct tcpcb *tp, struct tcphdr *th, uint32_t new_bytes_marked, in tcp_prague_process_ecn()
690 tcp_prague_delay_ack(struct tcpcb *tp, struct tcphdr *th) in tcp_prague_delay_ack()
H A Dtcpip.h74 struct tcphdr ti_t; /* tcp header */
82 struct tcphdr ti_t; /* tcp header */
H A Dtcp.h87 #define tcp6hdr tcphdr /* for KAME src sync over BSD*'s */
93 struct tcphdr { struct
214 #define TCP_MAXOLEN (TCP_MAXHLEN - sizeof(struct tcphdr))
H A Dtcp_subr.c596 #define TCP_MINPROTOHDR (sizeof(struct ip6_hdr) + sizeof(struct tcphdr)) in tcp_init()
667 struct tcphdr *tcp_hdr = (struct tcphdr *)tcp_ptr; in tcp_fillheaders()
677 ip6->ip6_plen = htons(sizeof(struct tcphdr)); in tcp_fillheaders()
689 htonl(sizeof(struct tcphdr) + IPPROTO_TCP)); in tcp_fillheaders()
705 htons(sizeof(struct tcphdr) + IPPROTO_TCP)); in tcp_fillheaders()
756 tcp_respond(struct tcpcb *tp, void *ipgen, struct tcphdr *th, struct mbuf *m, in tcp_respond()
764 struct tcphdr *nth; in tcp_respond()
815 nth = (struct tcphdr *)(void *)(ip6 + 1); in tcp_respond()
821 nth = (struct tcphdr *)(void *)(ip + 1); in tcp_respond()
823 bcopy((caddr_t)th, (caddr_t)nth, sizeof(struct tcphdr)); in tcp_respond()
[all …]
H A Dtcp_log.h95 extern void tcp_log_th_flags(void *hdr, struct tcphdr *th, struct tcpcb *tp, bool outgoing, struct …
98 extern void tcp_log_drop_pcb(void *hdr, struct tcphdr *th, struct tcpcb *tp, bool outgoing, const c…
99 extern void tcp_log_drop_pkt(void *hdr, struct tcphdr *th, struct ifnet *ifp, const char *reason);
H A Dtcp_ccdbg.c82 tcp_ccdbg_trace(struct tcpcb *tp, struct tcphdr *th, int32_t event) in tcp_ccdbg_trace()
146 struct tcpcb *, tp, struct tcphdr *, th, int32_t, event); in tcp_ccdbg_trace()
H A Dtcp_utils.h51 extern void tcp_ccdbg_trace(struct tcpcb *tp, struct tcphdr *th, int32_t event);
H A Dtcp_input.c278 static void tcp_dooptions(struct tcpcb *, u_char *, int, struct tcphdr *,
282 struct tcphdr *, struct mbuf *, int);
303 static void tcp_bad_rexmt_restore_state(struct tcpcb *tp, struct tcphdr *th);
305 struct tcphdr *th);
307 struct tcphdr *th);
308 static void tcp_early_rexmt_check(struct tcpcb *tp, struct tcphdr *th);
309 static void tcp_bad_rexmt_check(struct tcpcb *tp, struct tcphdr *th,
336 static void tcp_newreno_partial_ack(struct tcpcb *tp, struct tcphdr *th);
560 tcp_reass(struct tcpcb *tp, struct tcphdr *th, int *tlenp, struct mbuf *m, in tcp_reass()
947 IP6_EXTHDR_CHECK(m, *offp, sizeof(struct tcphdr), return IPPROTO_DONE); in tcp6_input()
[all …]
H A Dip_icmp.c267 struct tcphdr *th = NULL; in icmp_error()
275 if (oiphlen + sizeof(struct tcphdr) > n->m_len && in icmp_error()
284 if (n->m_len < (oiphlen + sizeof(struct tcphdr)) && in icmp_error()
285 (n = m_pullup(n, (oiphlen + sizeof(struct tcphdr)))) == NULL) { in icmp_error()
294 th = (struct tcphdr *)(void *)((caddr_t)oip + oiphlen); in icmp_error()
296 if (th != ((struct tcphdr *)P2ROUNDDOWN(th, in icmp_error()
304 if (tcphlen < sizeof(struct tcphdr)) { in icmp_error()
323 th = (struct tcphdr *)(void *)((caddr_t)oip + oiphlen); in icmp_error()
H A Dmptcp_opt.h37 extern void tcp_do_mptcp_options(struct tcpcb *, u_char *, struct tcphdr *,
H A Dtcp_var.h170 struct tcphdr *tqe_th; /* a pointer to tcp header */
243 struct tcphdr tt_t;
1804 void tcp_respond(struct tcpcb *, void *, struct tcphdr *, struct mbuf *,
1818 void tcp_trace(int, int, struct tcpcb *, void *, struct tcphdr *, int);
1821 void tcp_sack_doack(struct tcpcb *, struct tcpopt *, struct tcphdr *,
1824 struct tcphdr *, boolean_t *);
1825 int tcp_detect_bad_rexmt(struct tcpcb *, struct tcphdr *, struct tcpopt *,
1831 void tcp_sack_partialack(struct tcpcb *, struct tcphdr *);
1836 uint8_t tcp_get_ace(struct tcphdr *th);
1905 extern int tcp_input_checksum(int, struct mbuf *, struct tcphdr *, int, int);
[all …]
H A Dtcp_rledbat.c43 void tcp_rledbat_data_rcvd(struct tcpcb *tp, struct tcphdr *th,
219 tcp_rledbat_data_rcvd(struct tcpcb *tp, struct tcphdr *th, in tcp_rledbat_data_rcvd()
/xnu-11215.81.4/bsd/skywalk/nexus/flowswitch/flow/
H A Dflow_classifier.c94 volatile struct tcphdr *_tcph; in flow_pkt_classify()
139 (offsetof(struct tcphdr, th_dport) - in flow_pkt_classify()
140 offsetof(struct tcphdr, th_sport))); in flow_pkt_classify()
143 (offsetof(struct tcphdr, th_seq) - in flow_pkt_classify()
144 offsetof(struct tcphdr, th_sport))); in flow_pkt_classify()
147 (offsetof(struct tcphdr, th_ack) - in flow_pkt_classify()
148 offsetof(struct tcphdr, th_sport))); in flow_pkt_classify()
151 (offsetof(struct tcphdr, th_flags) - in flow_pkt_classify()
152 offsetof(struct tcphdr, th_sport))); in flow_pkt_classify()
155 (offsetof(struct tcphdr, th_win) - in flow_pkt_classify()
[all …]
H A Dflow_agg.c119 struct tcphdr tcp_m;
169 struct tcphdr tcp_m;
340 struct tcphdr *tcp = in mbuf_csum()
341 (struct tcphdr *)(void *)(mtod(m, uint8_t *) + in mbuf_csum()
983 (sizeof(struct tcphdr) + TCPOLEN_TSTAMP_APPA))) { in can_agg_fastpath()
1147 struct tcphdr *stcp = (struct tcphdr *)(void *)(sl3_hdr + sl3hlen); in can_agg_slowpath()
1149 struct tcphdr *tcp = __unsafe_forge_bidi_indexable(struct tcphdr *, in can_agg_slowpath()
1176 uint8_t tcp_opts_len = pkt->pkt_flow_tcp_hlen - sizeof(struct tcphdr); in can_agg_slowpath()
1313 struct tcphdr *stcp, *tcp; in flow_agg_merge_hdr()
1389 stcp = (struct tcphdr *)(void *)(l3hdr + l3hlen); in flow_agg_merge_hdr()
[all …]
H A Dflow_track.c65 ASSERT(hlen >= (int)sizeof(struct tcphdr)); in flow_track_tcp_get_wscale()
67 opt = hdr + sizeof(struct tcphdr); in flow_track_tcp_get_wscale()
68 hlen -= sizeof(struct tcphdr); in flow_track_tcp_get_wscale()
758 struct tcphdr *th; in flow_track_abort_tcp()
769 tlen = sizeof(struct tcphdr); in flow_track_abort_tcp()
803 th = (struct tcphdr *)(void *)((char *)ip + sizeof(*ip)); in flow_track_abort_tcp()
818 th = (struct tcphdr *)(void *)((char *)ip6 + sizeof(*ip6)); in flow_track_abort_tcp()
/xnu-11215.81.4/tests/
H A Dicmp_fragmented_payload.c105 struct tcphdr *inner_tcp_hdr;
232 icmp4_pcb_set_payload(icmp4_pcb_t pcb, struct icmp *icmp_in, struct ip *ip_in, struct tcphdr *tcp_i… in icmp4_pcb_set_payload()
237 pcb->inner_tcp_hdr_len = sizeof(struct tcphdr); in icmp4_pcb_set_payload()
239 pcb->inner_tcp_hdr = (struct tcphdr*)(ptr + pcb->icmp_hdr_len + pcb->inner_ip_hdr_len); in icmp4_pcb_set_payload()
340 .ip_len = sizeof(struct ip) + sizeof(struct tcphdr),
345 struct tcphdr tcp_payload = {
/xnu-11215.81.4/bsd/net/
H A Dpf_osfp.c88 const struct tcphdr *tcp) in pf_osfp_fingerprint()
112 return pf_osfp_fingerprint_hdr(ip, ip6, (struct tcphdr *)(void *)hdr, sizeof(hdr)); in pf_osfp_fingerprint()
117 const struct tcphdr *__sized_by(tcphdr_max_len)tcp, size_t tcphdr_max_len) in pf_osfp_fingerprint_hdr()
122 uint8_t const *tcphdr = (uint8_t const *__bidi_indexable)tcp; in pf_osfp_fingerprint_hdr() local
123 uint8_t const *tcpopt_ptr = tcphdr + sizeof(struct tcphdr); in pf_osfp_fingerprint_hdr()
124 int tcpopt_cnt = (tcp->th_off << 2) + sizeof(struct tcphdr); in pf_osfp_fingerprint_hdr()
461 #define MTUOFF (sizeof (struct ip) + sizeof (struct tcphdr)) in pf_osfp_find()
H A Dpacket_mangler.c693 struct tcphdr tcp; in pktmnglr_ipfilter_output()
764 struct tcphdr tcp; in pktmnglr_ipfilter_input()
906 if (off < sizeof(struct tcphdr) || off > ip_pld_len) { in pktmnglr_ipfilter_input()
911 tcp_optlen = off - sizeof(struct tcphdr); in pktmnglr_ipfilter_input()
917 …error = mbuf_copydata(*data, (size_t)offset + sizeof(struct tcphdr), orig_tcp_optlen, tcp_opt_buf); in pktmnglr_ipfilter_input()
998 (size_t)offset + sizeof(struct tcphdr), in pktmnglr_ipfilter_input()
1043 struct tcphdr *tcp; in chksm_update()
1059 tcp = (struct tcphdr *)(void *)(ptr + (ip->ip_hl << 2)); in chksm_update()
H A Dpf_norm.c168 struct pf_pdesc *, pbuf_t *, struct tcphdr *, int, int *);
2599 struct tcphdr *__single th = pf_pd_get_hdr_tcp(pd); in pf_normalize_tcp()
2691 if (th->th_off < (sizeof(struct tcphdr) >> 2)) { in pf_normalize_tcp()
2699 …uint8_t *__bidi_indexable th_iter = (uint8_t * __bidi_indexable)(struct tcphdr *__bidi_indexable) … in pf_normalize_tcp()
2701 ov = *(u_int16_t *)(void *)(th_iter + offsetof(struct tcphdr, th_ack) + sizeof(th->th_ack)); in pf_normalize_tcp()
2704 nv = *(u_int16_t *)(void *)(th_iter + offsetof(struct tcphdr, th_ack) + sizeof(th->th_ack)); in pf_normalize_tcp()
2754 struct tcphdr *th, struct pf_state_peer *src, struct pf_state_peer *dst) in pf_normalize_tcp_init()
2793 if (th->th_off > (sizeof(struct tcphdr) >> 2) && src->scrub && in pf_normalize_tcp_init()
2796 int hlen = (th->th_off << 2) - sizeof(struct tcphdr); in pf_normalize_tcp_init()
2797 u_int8_t *opt = hdr + sizeof(struct tcphdr); in pf_normalize_tcp_init()
[all …]
/xnu-11215.81.4/bsd/skywalk/nexus/netif/
H A Dnx_netif_gso.c115 struct tcphdr *tcp;
431 state->tcp = (struct tcphdr *)(void *)(baddr + pkt->pkt_headroom + in netif_gso_ipv4_tcp_update()
503 state->tcp = (struct tcphdr *)(void *)(baddr + pkt->pkt_headroom + in netif_gso_ipv6_tcp_update()
568 state->tcp = (struct tcphdr *)(void *)(m_mtod_current(m) + in netif_gso_ip_tcp_init_state()
589 state->tcp = (struct tcphdr *)(void *)(m_mtod_current(m) + in netif_gso_ip_tcp_init_state()
666 hlen = mac_hlen + ip_hlen + sizeof(struct tcphdr); in netif_gso_ipv4_tcp()
740 hlen = mac_hlen + ip_hlen + sizeof(struct tcphdr); in netif_gso_ipv6_tcp()
/xnu-11215.81.4/bsd/dev/dtrace/scripts/
H A Dtcp.d126 struct tcphdr *tcp_hdr; /* raw TCP header */
130 translator tcpinfo_t < struct tcphdr *T > {

12