Lines Matching refs:sock
52 void tcp_time_wait(struct sock *sk, int state, int timeo);
258 static inline bool tcp_under_memory_pressure(const struct sock *sk) in tcp_under_memory_pressure()
283 static inline bool tcp_out_of_memory(struct sock *sk) in tcp_out_of_memory()
291 void sk_forced_mem_schedule(struct sock *sk, int size);
293 static inline bool tcp_too_many_orphans(struct sock *sk, int shift) in tcp_too_many_orphans()
306 bool tcp_check_oom(struct sock *sk, int shift);
320 void tcp_shutdown(struct sock *sk, int how);
326 int tcp_sendmsg(struct sock *sk, struct msghdr *msg, size_t size);
327 int tcp_sendmsg_locked(struct sock *sk, struct msghdr *msg, size_t size);
328 int tcp_sendpage(struct sock *sk, struct page *page, int offset, size_t size,
330 int tcp_sendpage_locked(struct sock *sk, struct page *page, int offset,
332 ssize_t do_tcp_sendpages(struct sock *sk, struct page *page, int offset,
334 int tcp_send_mss(struct sock *sk, int *size_goal, int flags);
335 void tcp_push(struct sock *sk, int flags, int mss_now, int nonagle,
337 void tcp_release_cb(struct sock *sk);
339 void tcp_write_timer_handler(struct sock *sk);
340 void tcp_delack_timer_handler(struct sock *sk);
341 int tcp_ioctl(struct sock *sk, int cmd, unsigned long arg);
342 int tcp_rcv_state_process(struct sock *sk, struct sk_buff *skb);
343 void tcp_rcv_established(struct sock *sk, struct sk_buff *skb);
344 void tcp_rcv_space_adjust(struct sock *sk);
345 int tcp_twsk_unique(struct sock *sk, struct sock *sktw, void *twp);
346 void tcp_twsk_destructor(struct sock *sk);
351 void tcp_enter_quickack_mode(struct sock *sk, unsigned int max_quickacks);
352 static inline void tcp_dec_quickack_mode(struct sock *sk, in tcp_dec_quickack_mode()
383 struct sock *tcp_check_req(struct sock *sk, struct sk_buff *skb,
386 int tcp_child_process(struct sock *parent, struct sock *child,
388 void tcp_enter_loss(struct sock *sk);
389 void tcp_cwnd_reduction(struct sock *sk, int newly_acked_sacked, int flag);
391 void tcp_update_metrics(struct sock *sk);
392 void tcp_init_metrics(struct sock *sk);
395 void tcp_close(struct sock *sk, long timeout);
396 void tcp_init_sock(struct sock *sk);
397 void tcp_init_transfer(struct sock *sk, int bpf_op, struct sk_buff *skb);
398 __poll_t tcp_poll(struct file *file, struct socket *sock,
400 int tcp_getsockopt(struct sock *sk, int level, int optname,
402 int tcp_setsockopt(struct sock *sk, int level, int optname, sockptr_t optval,
404 void tcp_set_keepalive(struct sock *sk, int val);
406 int tcp_recvmsg(struct sock *sk, struct msghdr *msg, size_t len, int nonblock,
408 int tcp_set_rcvlowat(struct sock *sk, int val);
409 void tcp_data_ready(struct sock *sk);
411 int tcp_mmap(struct file *file, struct socket *sock,
422 u16 tcp_v4_get_syncookie(struct sock *sk, struct iphdr *iph,
424 u16 tcp_v6_get_syncookie(struct sock *sk, struct ipv6hdr *iph,
428 struct sock *sk, struct tcphdr *th);
433 void tcp_v4_send_check(struct sock *sk, struct sk_buff *skb);
434 void tcp_v4_mtu_reduced(struct sock *sk);
435 void tcp_req_err(struct sock *sk, u32 seq, bool abort);
436 void tcp_ld_RTO_revert(struct sock *sk, u32 seq);
437 int tcp_v4_conn_request(struct sock *sk, struct sk_buff *skb);
438 struct sock *tcp_create_openreq_child(const struct sock *sk,
441 void tcp_ca_openreq_child(struct sock *sk, const struct dst_entry *dst);
442 struct sock *tcp_v4_syn_recv_sock(const struct sock *sk, struct sk_buff *skb,
447 int tcp_v4_do_rcv(struct sock *sk, struct sk_buff *skb);
448 int tcp_v4_connect(struct sock *sk, struct sockaddr *uaddr, int addr_len);
449 int tcp_connect(struct sock *sk);
455 struct sk_buff *tcp_make_synack(const struct sock *sk, struct dst_entry *dst,
460 int tcp_disconnect(struct sock *sk, int flags);
462 void tcp_finish_connect(struct sock *sk, struct sk_buff *skb);
463 int tcp_send_rcvq(struct sock *sk, struct msghdr *msg, size_t size);
464 void inet_sk_rx_dst_set(struct sock *sk, const struct sk_buff *skb);
467 struct sock *tcp_get_cookie_sock(struct sock *sk, struct sk_buff *skb,
472 struct sock *cookie_v4_check(struct sock *sk, struct sk_buff *skb);
475 struct sock *sk, struct sk_buff *skb);
493 static inline void tcp_synq_overflow(const struct sock *sk) in tcp_synq_overflow()
517 static inline bool tcp_synq_no_recent_overflow(const struct sock *sk) in tcp_synq_no_recent_overflow()
567 struct sock *cookie_v6_check(struct sock *sk, struct sk_buff *skb);
575 void __tcp_push_pending_frames(struct sock *sk, unsigned int cur_mss,
577 int __tcp_retransmit_skb(struct sock *sk, struct sk_buff *skb, int segs);
578 int tcp_retransmit_skb(struct sock *sk, struct sk_buff *skb, int segs);
579 void tcp_retransmit_timer(struct sock *sk);
580 void tcp_xmit_retransmit_queue(struct sock *);
581 void tcp_simple_retransmit(struct sock *);
582 void tcp_enter_recovery(struct sock *sk, bool ece_ack);
583 int tcp_trim_head(struct sock *, struct sk_buff *, u32);
588 int tcp_fragment(struct sock *sk, enum tcp_queue tcp_queue,
592 void tcp_send_probe0(struct sock *);
593 void tcp_send_partial(struct sock *);
594 int tcp_write_wakeup(struct sock *, int mib);
595 void tcp_send_fin(struct sock *sk);
596 void tcp_send_active_reset(struct sock *sk, gfp_t priority);
597 int tcp_send_synack(struct sock *);
598 void tcp_push_one(struct sock *, unsigned int mss_now);
599 void __tcp_send_ack(struct sock *sk, u32 rcv_nxt);
600 void tcp_send_ack(struct sock *sk);
601 void tcp_send_delayed_ack(struct sock *sk);
602 void tcp_send_loss_probe(struct sock *sk);
603 bool tcp_schedule_loss_probe(struct sock *sk, bool advancing_rto);
608 void tcp_rearm_rto(struct sock *sk);
609 void tcp_synack_rtt_meas(struct sock *sk, struct request_sock *req);
610 void tcp_reset(struct sock *sk);
612 void tcp_fin(struct sock *sk);
613 void tcp_check_space(struct sock *sk);
616 void tcp_init_xmit_timers(struct sock *);
617 static inline void tcp_clear_xmit_timers(struct sock *sk) in tcp_clear_xmit_timers()
628 unsigned int tcp_sync_mss(struct sock *sk, u32 pmtu);
629 unsigned int tcp_current_mss(struct sock *sk);
630 u32 tcp_clamp_probe0_to_user_timeout(const struct sock *sk, u32 when);
656 void tcp_get_info(struct sock *, struct tcp_info *);
659 int tcp_read_sock(struct sock *sk, read_descriptor_t *desc,
662 void tcp_initialize_rcv_mss(struct sock *sk);
664 int tcp_mtu_to_mss(struct sock *sk, int pmtu);
665 int tcp_mss_to_mtu(struct sock *sk, int mss);
666 void tcp_mtup_init(struct sock *sk);
668 static inline void tcp_bound_rto(const struct sock *sk) in tcp_bound_rto()
682 if (sk_is_mptcp((struct sock *)tp)) in __tcp_fast_path_on()
695 static inline void tcp_fast_path_check(struct sock *sk) in tcp_fast_path_check()
707 static inline u32 tcp_rto_min(struct sock *sk) in tcp_rto_min()
717 static inline u32 tcp_rto_min_us(struct sock *sk) in tcp_rto_min_us()
750 u32 __tcp_select_window(struct sock *sk);
752 void tcp_send_window_probe(struct sock *sk);
888 struct sock *sk_redir;
906 static inline struct sock *tcp_skb_bpf_redirect_fetch(struct sk_buff *skb) in tcp_skb_bpf_redirect_fetch()
946 INDIRECT_CALLABLE_DECLARE(void tcp_v6_send_check(struct sock *sk, struct sk_buff *skb));
1068 void (*init)(struct sock *sk);
1070 void (*release)(struct sock *sk);
1073 u32 (*ssthresh)(struct sock *sk);
1075 void (*cong_avoid)(struct sock *sk, u32 ack, u32 acked);
1077 void (*set_state)(struct sock *sk, u8 new_state);
1079 void (*cwnd_event)(struct sock *sk, enum tcp_ca_event ev);
1081 void (*in_ack_event)(struct sock *sk, u32 flags);
1083 u32 (*undo_cwnd)(struct sock *sk);
1085 void (*pkts_acked)(struct sock *sk, const struct ack_sample *sample);
1087 u32 (*min_tso_segs)(struct sock *sk);
1089 u32 (*sndbuf_expand)(struct sock *sk);
1093 void (*cong_control)(struct sock *sk, const struct rate_sample *rs);
1095 size_t (*get_info)(struct sock *sk, u32 ext, int *attr,
1105 void tcp_assign_congestion_control(struct sock *sk);
1106 void tcp_init_congestion_control(struct sock *sk);
1107 void tcp_cleanup_congestion_control(struct sock *sk);
1113 int tcp_set_congestion_control(struct sock *sk, const char *name, bool load,
1118 u32 tcp_reno_ssthresh(struct sock *sk);
1119 u32 tcp_reno_undo_cwnd(struct sock *sk);
1120 void tcp_reno_cong_avoid(struct sock *sk, u32 ack, u32 acked);
1135 static inline bool tcp_ca_needs_ecn(const struct sock *sk) in tcp_ca_needs_ecn()
1142 static inline void tcp_set_ca_state(struct sock *sk, const u8 ca_state) in tcp_set_ca_state()
1151 static inline void tcp_ca_event(struct sock *sk, const enum tcp_ca_event event) in tcp_ca_event()
1160 void tcp_rate_skb_sent(struct sock *sk, struct sk_buff *skb);
1161 void tcp_rate_skb_delivered(struct sock *sk, struct sk_buff *skb,
1163 void tcp_rate_gen(struct sock *sk, u32 delivered, u32 lost,
1165 void tcp_rate_check_app_limited(struct sock *sk);
1220 static inline bool tcp_in_cwnd_reduction(const struct sock *sk) in tcp_in_cwnd_reduction()
1230 static inline __u32 tcp_current_ssthresh(const struct sock *sk) in tcp_current_ssthresh()
1245 void tcp_enter_cwr(struct sock *sk);
1275 static inline bool tcp_is_cwnd_limited(const struct sock *sk) in tcp_is_cwnd_limited()
1295 static inline bool tcp_needs_internal_pacing(const struct sock *sk) in tcp_needs_internal_pacing()
1303 static inline unsigned long tcp_pacing_delay(const struct sock *sk) in tcp_pacing_delay()
1310 static inline void tcp_reset_xmit_timer(struct sock *sk, in tcp_reset_xmit_timer()
1325 static inline unsigned long tcp_probe0_base(const struct sock *sk) in tcp_probe0_base()
1331 static inline unsigned long tcp_probe0_when(const struct sock *sk, in tcp_probe0_when()
1339 static inline void tcp_check_probe_timer(struct sock *sk) in tcp_check_probe_timer()
1371 bool tcp_add_backlog(struct sock *sk, struct sk_buff *skb);
1372 int tcp_filter(struct sock *sk, struct sk_buff *skb);
1373 void tcp_set_state(struct sock *sk, int state);
1374 void tcp_done(struct sock *sk);
1375 int tcp_abort(struct sock *sk, int err);
1383 void tcp_cwnd_restart(struct sock *sk, s32 delta);
1385 static inline void tcp_slow_start_after_idle_check(struct sock *sk) in tcp_slow_start_after_idle_check()
1400 void tcp_select_initial_window(const struct sock *sk, int __space,
1405 static inline int tcp_win_from_space(const struct sock *sk, int space) in tcp_win_from_space()
1415 static inline int tcp_space(const struct sock *sk) in tcp_space()
1422 static inline int tcp_full_space(const struct sock *sk) in tcp_full_space()
1427 void tcp_cleanup_rbuf(struct sock *sk, int copied);
1434 static inline bool tcp_rmem_pressure(const struct sock *sk) in tcp_rmem_pressure()
1448 const struct sock *sk_listener,
1451 void tcp_enter_memory_pressure(struct sock *sk);
1452 void tcp_leave_memory_pressure(struct sock *sk);
1456 struct net *net = sock_net((struct sock *)tp); in keepalive_intvl_when()
1464 struct net *net = sock_net((struct sock *)tp); in keepalive_time_when()
1472 struct net *net = sock_net((struct sock *)tp); in keepalive_probes()
1486 static inline int tcp_fin_time(const struct sock *sk) in tcp_fin_time()
1620 const struct sock *sk, const struct sk_buff *skb);
1621 int tcp_md5_do_add(struct sock *sk, const union tcp_md5_addr *addr,
1624 int tcp_md5_do_del(struct sock *sk, const union tcp_md5_addr *addr,
1626 struct tcp_md5sig_key *tcp_v4_md5_lookup(const struct sock *sk,
1627 const struct sock *addr_sk);
1632 struct tcp_md5sig_key *__tcp_md5_do_lookup(const struct sock *sk, int l3index,
1636 tcp_md5_do_lookup(const struct sock *sk, int l3index, in tcp_md5_do_lookup()
1647 tcp_md5_do_lookup(const struct sock *sk, int l3index, in tcp_md5_do_lookup()
1669 void tcp_fastopen_cache_get(struct sock *sk, u16 *mss,
1671 void tcp_fastopen_cache_set(struct sock *sk, u16 mss,
1683 void tcp_fastopen_destroy_cipher(struct sock *sk);
1685 int tcp_fastopen_reset_cipher(struct net *net, struct sock *sk,
1689 void tcp_fastopen_add_skb(struct sock *sk, struct sk_buff *skb);
1690 struct sock *tcp_try_fastopen(struct sock *sk, struct sk_buff *skb,
1695 bool tcp_fastopen_cookie_check(struct sock *sk, u16 *mss,
1697 bool tcp_fastopen_defer_connect(struct sock *sk, int *err);
1711 void tcp_fastopen_active_disable(struct sock *sk);
1712 bool tcp_fastopen_active_should_disable(struct sock *sk);
1713 void tcp_fastopen_active_disable_ofo_check(struct sock *sk);
1714 void tcp_fastopen_active_detect_blackhole(struct sock *sk, bool expired);
1718 struct tcp_fastopen_context *tcp_fastopen_get_ctx(const struct sock *sk) in tcp_fastopen_get_ctx()
1756 void tcp_chrono_start(struct sock *sk, const enum tcp_chrono type);
1757 void tcp_chrono_stop(struct sock *sk, const enum tcp_chrono type);
1776 void tcp_write_queue_purge(struct sock *sk);
1778 static inline struct sk_buff *tcp_rtx_queue_head(const struct sock *sk) in tcp_rtx_queue_head()
1783 static inline struct sk_buff *tcp_rtx_queue_tail(const struct sock *sk) in tcp_rtx_queue_tail()
1788 static inline struct sk_buff *tcp_write_queue_head(const struct sock *sk) in tcp_write_queue_head()
1793 static inline struct sk_buff *tcp_write_queue_tail(const struct sock *sk) in tcp_write_queue_tail()
1801 static inline struct sk_buff *tcp_send_head(const struct sock *sk) in tcp_send_head()
1806 static inline bool tcp_skb_is_last(const struct sock *sk, in tcp_skb_is_last()
1819 static inline bool tcp_write_queue_empty(const struct sock *sk) in tcp_write_queue_empty()
1826 static inline bool tcp_rtx_queue_empty(const struct sock *sk) in tcp_rtx_queue_empty()
1831 static inline bool tcp_rtx_and_write_queues_empty(const struct sock *sk) in tcp_rtx_and_write_queues_empty()
1836 static inline void tcp_add_write_queue_tail(struct sock *sk, struct sk_buff *skb) in tcp_add_write_queue_tail()
1848 struct sock *sk) in tcp_insert_write_queue_before()
1853 static inline void tcp_unlink_write_queue(struct sk_buff *skb, struct sock *sk) in tcp_unlink_write_queue()
1861 static inline void tcp_rtx_queue_unlink(struct sk_buff *skb, struct sock *sk) in tcp_rtx_queue_unlink()
1867 static inline void tcp_rtx_queue_unlink_and_free(struct sk_buff *skb, struct sock *sk) in tcp_rtx_queue_unlink_and_free()
1874 static inline void tcp_push_pending_frames(struct sock *sk) in tcp_push_pending_frames()
1898 static inline void tcp_advance_highest_sack(struct sock *sk, struct sk_buff *skb) in tcp_advance_highest_sack()
1903 static inline struct sk_buff *tcp_highest_sack(struct sock *sk) in tcp_highest_sack()
1908 static inline void tcp_highest_sack_reset(struct sock *sk) in tcp_highest_sack_reset()
1914 static inline void tcp_highest_sack_replace(struct sock *sk, in tcp_highest_sack_replace()
1923 static inline bool inet_sk_transparent(const struct sock *sk) in inet_sk_transparent()
1959 struct sock *syn_wait_sk;
1968 void tcp_v4_destroy_sock(struct sock *sk);
1983 struct net *net = sock_net((struct sock *)tp); in tcp_notsent_lowat()
1991 static inline bool tcp_stream_memory_free(const struct sock *sk, int wake) in tcp_stream_memory_free()
2005 int tcp_rtx_synack(const struct sock *sk, struct request_sock *req);
2008 struct sock *sk, struct sk_buff *skb);
2013 struct tcp_md5sig_key *(*md5_lookup) (const struct sock *sk,
2014 const struct sock *addr_sk);
2017 const struct sock *sk,
2019 int (*md5_parse)(struct sock *sk,
2029 struct tcp_md5sig_key *(*req_md5_lookup)(const struct sock *sk,
2030 const struct sock *addr_sk);
2033 const struct sock *sk,
2037 const struct sock *sk_listener,
2043 struct dst_entry *(*route_req)(const struct sock *sk, struct flowi *fl,
2047 int (*send_synack)(const struct sock *sk, struct dst_entry *dst,
2061 const struct sock *sk, struct sk_buff *skb, in cookie_init_sequence()
2070 const struct sock *sk, struct sk_buff *skb, in cookie_init_sequence()
2083 void tcp_mark_skb_lost(struct sock *sk, struct sk_buff *skb);
2084 void tcp_newreno_mark_lost(struct sock *sk, bool snd_una_advanced);
2087 extern bool tcp_rack_mark_lost(struct sock *sk);
2090 extern void tcp_rack_reo_timeout(struct sock *sk);
2091 extern void tcp_rack_update_reo_wnd(struct sock *sk, struct rate_sample *rs);
2094 static inline s64 tcp_rto_delta_us(const struct sock *sk) in tcp_rto_delta_us()
2139 static inline int tcp_inq(struct sock *sk) in tcp_inq()
2163 int tcp_peek_len(struct socket *sock);
2182 static inline void tcp_listendrop(const struct sock *sk) in tcp_listendrop()
2184 atomic_inc(&((struct sock *)sk)->sk_drops); in tcp_listendrop()
2202 int (*init)(struct sock *sk);
2204 void (*update)(struct sock *sk, struct proto *p,
2205 void (*write_space)(struct sock *sk));
2207 void (*release)(struct sock *sk);
2209 int (*get_info)(const struct sock *sk, struct sk_buff *skb);
2210 size_t (*get_info_size)(const struct sock *sk);
2212 void (*clone)(const struct request_sock *req, struct sock *newsk,
2220 int tcp_set_ulp(struct sock *sk, const char *name);
2222 void tcp_cleanup_ulp(struct sock *sk);
2223 void tcp_update_ulp(struct sock *sk, struct proto *p,
2224 void (*write_space)(struct sock *sk));
2234 struct proto *tcp_bpf_get_proto(struct sock *sk, struct sk_psock *psock);
2235 void tcp_bpf_clone(const struct sock *sk, struct sock *newsk);
2237 static inline void tcp_bpf_clone(const struct sock *sk, struct sock *newsk) in tcp_bpf_clone()
2243 int tcp_bpf_sendmsg_redir(struct sock *sk, struct sk_msg *msg, u32 bytes,
2245 int __tcp_bpf_recvmsg(struct sock *sk, struct sk_psock *psock,
2271 static inline int tcp_call_bpf(struct sock *sk, int op, u32 nargs, u32 *args) in tcp_call_bpf()
2295 static inline int tcp_call_bpf_2arg(struct sock *sk, int op, u32 arg1, u32 arg2) in tcp_call_bpf_2arg()
2302 static inline int tcp_call_bpf_3arg(struct sock *sk, int op, u32 arg1, u32 arg2, in tcp_call_bpf_3arg()
2311 static inline int tcp_call_bpf(struct sock *sk, int op, u32 nargs, u32 *args) in tcp_call_bpf()
2316 static inline int tcp_call_bpf_2arg(struct sock *sk, int op, u32 arg1, u32 arg2) in tcp_call_bpf_2arg()
2321 static inline int tcp_call_bpf_3arg(struct sock *sk, int op, u32 arg1, u32 arg2, in tcp_call_bpf_3arg()
2329 static inline u32 tcp_timeout_init(struct sock *sk) in tcp_timeout_init()
2340 static inline u32 tcp_rwnd_init_bpf(struct sock *sk) in tcp_rwnd_init_bpf()
2351 static inline bool tcp_bpf_ca_needs_ecn(struct sock *sk) in tcp_bpf_ca_needs_ecn()
2356 static inline void tcp_bpf_rtt(struct sock *sk) in tcp_bpf_rtt()
2368 void (*cad)(struct sock *sk, u32 ack_seq));
2384 static inline u64 tcp_transmit_time(const struct sock *sk) in tcp_transmit_time()