aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/sunrpc/xprt.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux/sunrpc/xprt.h')
-rw-r--r--include/linux/sunrpc/xprt.h61
1 files changed, 35 insertions, 26 deletions
diff --git a/include/linux/sunrpc/xprt.h b/include/linux/sunrpc/xprt.h
index d5223993fca9..bfbc492ae36d 100644
--- a/include/linux/sunrpc/xprt.h
+++ b/include/linux/sunrpc/xprt.h
@@ -1,5 +1,5 @@
1/* 1/*
2 * linux/include/linux/sunrpc/clnt_xprt.h 2 * linux/include/linux/sunrpc/xprt.h
3 * 3 *
4 * Declarations for the RPC transport interface. 4 * Declarations for the RPC transport interface.
5 * 5 *
@@ -150,8 +150,8 @@ struct rpc_xprt {
150 unsigned long cong; /* current congestion */ 150 unsigned long cong; /* current congestion */
151 unsigned long cwnd; /* congestion window */ 151 unsigned long cwnd; /* congestion window */
152 152
153 unsigned int rcvsize, /* socket receive buffer size */ 153 unsigned int rcvsize, /* transport rcv buffer size */
154 sndsize; /* socket send buffer size */ 154 sndsize; /* transport send buffer size */
155 155
156 size_t max_payload; /* largest RPC payload size, 156 size_t max_payload; /* largest RPC payload size,
157 in bytes */ 157 in bytes */
@@ -184,12 +184,12 @@ struct rpc_xprt {
184 unsigned long tcp_copied, /* copied to request */ 184 unsigned long tcp_copied, /* copied to request */
185 tcp_flags; 185 tcp_flags;
186 /* 186 /*
187 * Connection of sockets 187 * Connection of transports
188 */ 188 */
189 struct work_struct sock_connect; 189 struct work_struct connect_worker;
190 unsigned short port; 190 unsigned short port;
191 /* 191 /*
192 * Disconnection of idle sockets 192 * Disconnection of idle transports
193 */ 193 */
194 struct work_struct task_cleanup; 194 struct work_struct task_cleanup;
195 struct timer_list timer; 195 struct timer_list timer;
@@ -219,27 +219,36 @@ struct rpc_xprt {
219 219
220#ifdef __KERNEL__ 220#ifdef __KERNEL__
221 221
222struct rpc_xprt * xprt_create_proto(int proto, struct sockaddr_in *addr, 222/*
223 struct rpc_timeout *toparms); 223 * Transport operations used by ULPs
224void xprt_disconnect(struct rpc_xprt *); 224 */
225int xprt_destroy(struct rpc_xprt *); 225struct rpc_xprt * xprt_create_proto(int proto, struct sockaddr_in *addr, struct rpc_timeout *to);
226void xprt_set_timeout(struct rpc_timeout *, unsigned int, 226void xprt_set_timeout(struct rpc_timeout *to, unsigned int retr, unsigned long incr);
227 unsigned long); 227
228struct rpc_rqst * xprt_lookup_rqst(struct rpc_xprt *, u32); 228/*
229void xprt_complete_rqst(struct rpc_xprt *, 229 * Generic internal transport functions
230 struct rpc_rqst *, int); 230 */
231void xprt_reserve(struct rpc_task *); 231void xprt_connect(struct rpc_task *task);
232int xprt_prepare_transmit(struct rpc_task *); 232void xprt_reserve(struct rpc_task *task);
233void xprt_transmit(struct rpc_task *); 233int xprt_prepare_transmit(struct rpc_task *task);
234void xprt_receive(struct rpc_task *); 234void xprt_transmit(struct rpc_task *task);
235void xprt_wake_pending_tasks(struct rpc_xprt *, int);
236int xprt_adjust_timeout(struct rpc_rqst *req); 235int xprt_adjust_timeout(struct rpc_rqst *req);
237void xprt_release(struct rpc_task *); 236void xprt_release(struct rpc_task *task);
238void xprt_connect(struct rpc_task *); 237int xprt_destroy(struct rpc_xprt *xprt);
239int xs_setup_udp(struct rpc_xprt *, 238
240 struct rpc_timeout *); 239/*
241int xs_setup_tcp(struct rpc_xprt *, 240 * Transport switch helper functions
242 struct rpc_timeout *); 241 */
242void xprt_wake_pending_tasks(struct rpc_xprt *xprt, int status);
243struct rpc_rqst * xprt_lookup_rqst(struct rpc_xprt *xprt, u32 xid);
244void xprt_complete_rqst(struct rpc_xprt *xprt, struct rpc_rqst *req, int copied);
245void xprt_disconnect(struct rpc_xprt *xprt);
246
247/*
248 * Socket transport setup operations
249 */
250int xs_setup_udp(struct rpc_xprt *xprt, struct rpc_timeout *to);
251int xs_setup_tcp(struct rpc_xprt *xprt, struct rpc_timeout *to);
243 252
244/* 253/*
245 * Reserved bit positions in xprt->state 254 * Reserved bit positions in xprt->state