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

TOMOYO Linux Cross Reference
Linux/include/linux/sunrpc/xprtsock.h

Version: ~ [ linux-5.17-rc1 ] ~ [ linux-5.16.2 ] ~ [ linux-5.15.16 ] ~ [ linux-5.14.21 ] ~ [ linux-5.13.19 ] ~ [ linux-5.12.19 ] ~ [ linux-5.11.22 ] ~ [ linux-5.10.93 ] ~ [ linux-5.9.16 ] ~ [ linux-5.8.18 ] ~ [ linux-5.7.19 ] ~ [ linux-5.6.19 ] ~ [ linux-5.5.19 ] ~ [ linux-5.4.173 ] ~ [ linux-5.3.18 ] ~ [ linux-5.2.21 ] ~ [ linux-5.1.21 ] ~ [ linux-5.0.21 ] ~ [ linux-4.20.17 ] ~ [ linux-4.19.225 ] ~ [ linux-4.18.20 ] ~ [ linux-4.17.19 ] ~ [ linux-4.16.18 ] ~ [ linux-4.15.18 ] ~ [ linux-4.14.262 ] ~ [ linux-4.13.16 ] ~ [ linux-4.12.14 ] ~ [ linux-4.11.12 ] ~ [ linux-4.10.17 ] ~ [ linux-4.9.297 ] ~ [ linux-4.8.17 ] ~ [ linux-4.7.10 ] ~ [ linux-4.6.7 ] ~ [ linux-4.5.7 ] ~ [ linux-4.4.299 ] ~ [ linux-4.3.6 ] ~ [ linux-4.2.8 ] ~ [ linux-4.1.52 ] ~ [ linux-4.0.9 ] ~ [ linux-3.18.140 ] ~ [ linux-3.16.85 ] ~ [ linux-3.14.79 ] ~ [ linux-3.12.74 ] ~ [ 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.5 ] ~ [ policy-sample ] ~
Architecture: ~ [ i386 ] ~ [ alpha ] ~ [ m68k ] ~ [ mips ] ~ [ ppc ] ~ [ sparc ] ~ [ sparc64 ] ~

  1 /* SPDX-License-Identifier: GPL-2.0 */
  2 /*
  3  *  linux/include/linux/sunrpc/xprtsock.h
  4  *
  5  *  Declarations for the RPC transport socket provider.
  6  */
  7 
  8 #ifndef _LINUX_SUNRPC_XPRTSOCK_H
  9 #define _LINUX_SUNRPC_XPRTSOCK_H
 10 
 11 int             init_socket_xprt(void);
 12 void            cleanup_socket_xprt(void);
 13 
 14 #define RPC_MIN_RESVPORT        (1U)
 15 #define RPC_MAX_RESVPORT        (65535U)
 16 #define RPC_DEF_MIN_RESVPORT    (665U)
 17 #define RPC_DEF_MAX_RESVPORT    (1023U)
 18 
 19 struct sock_xprt {
 20         struct rpc_xprt         xprt;
 21 
 22         /*
 23          * Network layer
 24          */
 25         struct socket *         sock;
 26         struct sock *           inet;
 27         struct file *           file;
 28 
 29         /*
 30          * State of TCP reply receive
 31          */
 32         struct {
 33                 struct {
 34                         __be32  fraghdr,
 35                                 xid,
 36                                 calldir;
 37                 } __attribute__((packed));
 38 
 39                 u32             offset,
 40                                 len;
 41 
 42                 unsigned long   copied;
 43         } recv;
 44 
 45         /*
 46          * State of TCP transmit queue
 47          */
 48         struct {
 49                 u32             offset;
 50         } xmit;
 51 
 52         /*
 53          * Connection of transports
 54          */
 55         unsigned long           sock_state;
 56         struct delayed_work     connect_worker;
 57         struct work_struct      error_worker;
 58         struct work_struct      recv_worker;
 59         struct mutex            recv_mutex;
 60         struct sockaddr_storage srcaddr;
 61         unsigned short          srcport;
 62         int                     xprt_err;
 63 
 64         /*
 65          * UDP socket buffer size parameters
 66          */
 67         size_t                  rcvsize,
 68                                 sndsize;
 69 
 70         struct rpc_timeout      tcp_timeout;
 71 
 72         /*
 73          * Saved socket callback addresses
 74          */
 75         void                    (*old_data_ready)(struct sock *);
 76         void                    (*old_state_change)(struct sock *);
 77         void                    (*old_write_space)(struct sock *);
 78         void                    (*old_error_report)(struct sock *);
 79 };
 80 
 81 /*
 82  * TCP RPC flags
 83  */
 84 #define XPRT_SOCK_CONNECTING    1U
 85 #define XPRT_SOCK_DATA_READY    (2)
 86 #define XPRT_SOCK_UPD_TIMEOUT   (3)
 87 #define XPRT_SOCK_WAKE_ERROR    (4)
 88 #define XPRT_SOCK_WAKE_WRITE    (5)
 89 #define XPRT_SOCK_WAKE_PENDING  (6)
 90 #define XPRT_SOCK_WAKE_DISCONNECT       (7)
 91 
 92 #endif /* _LINUX_SUNRPC_XPRTSOCK_H */
 93 

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

kernel.org | git.kernel.org | LWN.net | Project Home | Wiki (Japanese) | Wiki (English) | 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.

osdn.jp