~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

TOMOYO Linux Cross Reference
Linux/net/rds/tcp.h

Version: ~ [ linux-6.11.5 ] ~ [ linux-6.10.14 ] ~ [ linux-6.9.12 ] ~ [ linux-6.8.12 ] ~ [ linux-6.7.12 ] ~ [ linux-6.6.58 ] ~ [ linux-6.5.13 ] ~ [ linux-6.4.16 ] ~ [ linux-6.3.13 ] ~ [ linux-6.2.16 ] ~ [ linux-6.1.114 ] ~ [ linux-6.0.19 ] ~ [ linux-5.19.17 ] ~ [ linux-5.18.19 ] ~ [ linux-5.17.15 ] ~ [ linux-5.16.20 ] ~ [ linux-5.15.169 ] ~ [ linux-5.14.21 ] ~ [ linux-5.13.19 ] ~ [ linux-5.12.19 ] ~ [ linux-5.11.22 ] ~ [ linux-5.10.228 ] ~ [ linux-5.9.16 ] ~ [ linux-5.8.18 ] ~ [ linux-5.7.19 ] ~ [ linux-5.6.19 ] ~ [ linux-5.5.19 ] ~ [ linux-5.4.284 ] ~ [ linux-5.3.18 ] ~ [ linux-5.2.21 ] ~ [ linux-5.1.21 ] ~ [ linux-5.0.21 ] ~ [ linux-4.20.17 ] ~ [ linux-4.19.322 ] ~ [ linux-4.18.20 ] ~ [ linux-4.17.19 ] ~ [ linux-4.16.18 ] ~ [ linux-4.15.18 ] ~ [ linux-4.14.336 ] ~ [ linux-4.13.16 ] ~ [ linux-4.12.14 ] ~ [ linux-4.11.12 ] ~ [ linux-4.10.17 ] ~ [ linux-4.9.337 ] ~ [ linux-4.4.302 ] ~ [ linux-3.10.108 ] ~ [ linux-2.6.32.71 ] ~ [ linux-2.6.0 ] ~ [ linux-2.4.37.11 ] ~ [ unix-v6-master ] ~ [ ccs-tools-1.8.9 ] ~ [ policy-sample ] ~
Architecture: ~ [ i386 ] ~ [ alpha ] ~ [ m68k ] ~ [ mips ] ~ [ ppc ] ~ [ sparc ] ~ [ sparc64 ] ~

  1 /* SPDX-License-Identifier: GPL-2.0 */
  2 #ifndef _RDS_TCP_H
  3 #define _RDS_TCP_H
  4 
  5 #define RDS_TCP_PORT    16385
  6 
  7 struct rds_tcp_incoming {
  8         struct rds_incoming     ti_inc;
  9         struct sk_buff_head     ti_skb_list;
 10 };
 11 
 12 struct rds_tcp_connection {
 13 
 14         struct list_head        t_tcp_node;
 15         bool                    t_tcp_node_detached;
 16         struct rds_conn_path    *t_cpath;
 17         /* t_conn_path_lock synchronizes the connection establishment between
 18          * rds_tcp_accept_one and rds_tcp_conn_path_connect
 19          */
 20         struct mutex            t_conn_path_lock;
 21         struct socket           *t_sock;
 22         void                    *t_orig_write_space;
 23         void                    *t_orig_data_ready;
 24         void                    *t_orig_state_change;
 25 
 26         struct rds_tcp_incoming *t_tinc;
 27         size_t                  t_tinc_hdr_rem;
 28         size_t                  t_tinc_data_rem;
 29 
 30         /* XXX error report? */
 31         struct work_struct      t_conn_w;
 32         struct work_struct      t_send_w;
 33         struct work_struct      t_down_w;
 34         struct work_struct      t_recv_w;
 35 
 36         /* for info exporting only */
 37         struct list_head        t_list_item;
 38         u32                     t_last_sent_nxt;
 39         u32                     t_last_expected_una;
 40         u32                     t_last_seen_una;
 41 };
 42 
 43 struct rds_tcp_statistics {
 44         uint64_t        s_tcp_data_ready_calls;
 45         uint64_t        s_tcp_write_space_calls;
 46         uint64_t        s_tcp_sndbuf_full;
 47         uint64_t        s_tcp_connect_raced;
 48         uint64_t        s_tcp_listen_closed_stale;
 49 };
 50 
 51 /* tcp.c */
 52 bool rds_tcp_tune(struct socket *sock);
 53 void rds_tcp_set_callbacks(struct socket *sock, struct rds_conn_path *cp);
 54 void rds_tcp_reset_callbacks(struct socket *sock, struct rds_conn_path *cp);
 55 void rds_tcp_restore_callbacks(struct socket *sock,
 56                                struct rds_tcp_connection *tc);
 57 u32 rds_tcp_write_seq(struct rds_tcp_connection *tc);
 58 u32 rds_tcp_snd_una(struct rds_tcp_connection *tc);
 59 extern struct rds_transport rds_tcp_transport;
 60 void rds_tcp_accept_work(struct sock *sk);
 61 int rds_tcp_laddr_check(struct net *net, const struct in6_addr *addr,
 62                         __u32 scope_id);
 63 /* tcp_connect.c */
 64 int rds_tcp_conn_path_connect(struct rds_conn_path *cp);
 65 void rds_tcp_conn_path_shutdown(struct rds_conn_path *conn);
 66 void rds_tcp_state_change(struct sock *sk);
 67 
 68 /* tcp_listen.c */
 69 struct socket *rds_tcp_listen_init(struct net *net, bool isv6);
 70 void rds_tcp_listen_stop(struct socket *sock, struct work_struct *acceptor);
 71 void rds_tcp_listen_data_ready(struct sock *sk);
 72 int rds_tcp_accept_one(struct socket *sock);
 73 void rds_tcp_keepalive(struct socket *sock);
 74 void *rds_tcp_listen_sock_def_readable(struct net *net);
 75 
 76 /* tcp_recv.c */
 77 int rds_tcp_recv_init(void);
 78 void rds_tcp_recv_exit(void);
 79 void rds_tcp_data_ready(struct sock *sk);
 80 int rds_tcp_recv_path(struct rds_conn_path *cp);
 81 void rds_tcp_inc_free(struct rds_incoming *inc);
 82 int rds_tcp_inc_copy_to_user(struct rds_incoming *inc, struct iov_iter *to);
 83 
 84 /* tcp_send.c */
 85 void rds_tcp_xmit_path_prepare(struct rds_conn_path *cp);
 86 void rds_tcp_xmit_path_complete(struct rds_conn_path *cp);
 87 int rds_tcp_xmit(struct rds_connection *conn, struct rds_message *rm,
 88                  unsigned int hdr_off, unsigned int sg, unsigned int off);
 89 void rds_tcp_write_space(struct sock *sk);
 90 
 91 /* tcp_stats.c */
 92 DECLARE_PER_CPU(struct rds_tcp_statistics, rds_tcp_stats);
 93 #define rds_tcp_stats_inc(member) rds_stats_inc_which(rds_tcp_stats, member)
 94 unsigned int rds_tcp_stats_info_copy(struct rds_info_iterator *iter,
 95                                      unsigned int avail);
 96 
 97 #endif
 98 

~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

kernel.org | git.kernel.org | LWN.net | Project Home | SVN repository | Mail admin

Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.

sflogo.php