Home
last modified time | relevance | path

Searched refs:xprt (Results 1 – 25 of 45) sorted by relevance

12

/kernel/linux/linux-5.10/net/sunrpc/
Dxprt.c70 static void xprt_init(struct rpc_xprt *xprt, struct net *net);
71 static __be32 xprt_alloc_xid(struct rpc_xprt *xprt);
72 static void xprt_destroy(struct rpc_xprt *xprt);
216 static void xprt_clear_locked(struct rpc_xprt *xprt) in xprt_clear_locked() argument
218 xprt->snd_task = NULL; in xprt_clear_locked()
219 if (!test_bit(XPRT_CLOSE_WAIT, &xprt->state)) { in xprt_clear_locked()
221 clear_bit(XPRT_LOCKED, &xprt->state); in xprt_clear_locked()
224 queue_work(xprtiod_workqueue, &xprt->task_cleanup); in xprt_clear_locked()
236 int xprt_reserve_xprt(struct rpc_xprt *xprt, struct rpc_task *task) in xprt_reserve_xprt() argument
240 if (test_and_set_bit(XPRT_LOCKED, &xprt->state)) { in xprt_reserve_xprt()
[all …]
Dxprtsock.c60 static void xs_close(struct rpc_xprt *xprt);
61 static void xs_tcp_set_socket_timeouts(struct rpc_xprt *xprt,
227 static inline struct sockaddr *xs_addr(struct rpc_xprt *xprt) in xs_addr() argument
229 return (struct sockaddr *) &xprt->addr; in xs_addr()
232 static inline struct sockaddr_un *xs_addr_un(struct rpc_xprt *xprt) in xs_addr_un() argument
234 return (struct sockaddr_un *) &xprt->addr; in xs_addr_un()
237 static inline struct sockaddr_in *xs_addr_in(struct rpc_xprt *xprt) in xs_addr_in() argument
239 return (struct sockaddr_in *) &xprt->addr; in xs_addr_in()
242 static inline struct sockaddr_in6 *xs_addr_in6(struct rpc_xprt *xprt) in xs_addr_in6() argument
244 return (struct sockaddr_in6 *) &xprt->addr; in xs_addr_in6()
[all …]
Dbackchannel_rqst.c36 unsigned int xprt_bc_max_slots(struct rpc_xprt *xprt) in xprt_bc_max_slots() argument
45 static inline int xprt_need_to_requeue(struct rpc_xprt *xprt) in xprt_need_to_requeue() argument
47 return xprt->bc_alloc_count < xprt->bc_alloc_max; in xprt_need_to_requeue()
79 struct rpc_rqst *xprt_alloc_bc_req(struct rpc_xprt *xprt, gfp_t gfp_flags) in xprt_alloc_bc_req() argument
88 req->rq_xprt = xprt; in xprt_alloc_bc_req()
127 int xprt_setup_backchannel(struct rpc_xprt *xprt, unsigned int min_reqs) in xprt_setup_backchannel() argument
129 if (!xprt->ops->bc_setup) in xprt_setup_backchannel()
131 return xprt->ops->bc_setup(xprt, min_reqs); in xprt_setup_backchannel()
135 int xprt_setup_bc(struct rpc_xprt *xprt, unsigned int min_reqs) in xprt_setup_bc() argument
157 req = xprt_alloc_bc_req(xprt, GFP_KERNEL); in xprt_setup_bc()
[all …]
Dsvc_xprt.c29 static struct svc_deferred_req *svc_deferred_dequeue(struct svc_xprt *xprt);
33 static void svc_delete_xprt(struct svc_xprt *xprt);
144 struct svc_xprt *xprt = in svc_xprt_free() local
146 struct module *owner = xprt->xpt_class->xcl_owner; in svc_xprt_free()
147 if (test_bit(XPT_CACHE_AUTH, &xprt->xpt_flags)) in svc_xprt_free()
148 svcauth_unix_info_release(xprt); in svc_xprt_free()
149 put_cred(xprt->xpt_cred); in svc_xprt_free()
150 put_net(xprt->xpt_net); in svc_xprt_free()
152 if (xprt->xpt_bc_xprt) in svc_xprt_free()
153 xprt_put(xprt->xpt_bc_xprt); in svc_xprt_free()
[all …]
Dxprtmultipath.c30 struct rpc_xprt *xprt) in xprt_switch_add_xprt_locked() argument
32 if (unlikely(xprt_get(xprt) == NULL)) in xprt_switch_add_xprt_locked()
34 list_add_tail_rcu(&xprt->xprt_switch, &xps->xps_xprt_list); in xprt_switch_add_xprt_locked()
37 xps->xps_net = xprt->xprt_net; in xprt_switch_add_xprt_locked()
50 struct rpc_xprt *xprt) in rpc_xprt_switch_add_xprt() argument
52 if (xprt == NULL) in rpc_xprt_switch_add_xprt()
55 if (xps->xps_net == xprt->xprt_net || xps->xps_net == NULL) in rpc_xprt_switch_add_xprt()
56 xprt_switch_add_xprt_locked(xps, xprt); in rpc_xprt_switch_add_xprt()
61 struct rpc_xprt *xprt) in xprt_switch_remove_xprt_locked() argument
63 if (unlikely(xprt == NULL)) in xprt_switch_remove_xprt_locked()
[all …]
Dclnt.c264 struct rpc_xprt *xprt, in rpc_clnt_set_transport() argument
273 if (!xprt_bound(xprt)) in rpc_clnt_set_transport()
277 rcu_assign_pointer(clnt->cl_xprt, xprt); in rpc_clnt_set_transport()
359 struct rpc_xprt *xprt, in rpc_new_client() argument
405 timeout = xprt->timeout; in rpc_new_client()
412 rpc_clnt_set_transport(clnt, xprt, timeout); in rpc_new_client()
432 trace_rpc_clnt_new(clnt, xprt, program->name, args->servername); in rpc_new_client()
446 xprt_put(xprt); in rpc_new_client()
452 struct rpc_xprt *xprt) in rpc_create_xprt() argument
462 xps = xprt_switch_alloc(xprt, GFP_KERNEL); in rpc_create_xprt()
[all …]
Ddebugfs.c120 static int do_xprt_debugfs(struct rpc_clnt *clnt, struct rpc_xprt *xprt, void *numv) in do_xprt_debugfs() argument
127 if (IS_ERR_OR_NULL(xprt->debugfs)) in do_xprt_debugfs()
130 xprt->debugfs->d_name.name); in do_xprt_debugfs()
176 struct rpc_xprt *xprt = f->private; in xprt_info_show() local
178 seq_printf(f, "netid: %s\n", xprt->address_strings[RPC_DISPLAY_NETID]); in xprt_info_show()
179 seq_printf(f, "addr: %s\n", xprt->address_strings[RPC_DISPLAY_ADDR]); in xprt_info_show()
180 seq_printf(f, "port: %s\n", xprt->address_strings[RPC_DISPLAY_PORT]); in xprt_info_show()
181 seq_printf(f, "state: 0x%lx\n", xprt->state); in xprt_info_show()
189 struct rpc_xprt *xprt = inode->i_private; in xprt_info_open() local
191 ret = single_open(filp, xprt_info_show, xprt); in xprt_info_open()
[all …]
Drpcb_clnt.c147 static void rpcb_wake_rpcbind_waiters(struct rpc_xprt *xprt, int status) in rpcb_wake_rpcbind_waiters() argument
149 xprt_clear_binding(xprt); in rpcb_wake_rpcbind_waiters()
150 rpc_wake_up_status(&xprt->binding, status); in rpcb_wake_rpcbind_waiters()
649 struct rpc_xprt *xprt; in rpcb_getport_async() local
661 xprt = xprt_get(task->tk_xprt); in rpcb_getport_async()
665 rpc_sleep_on_timeout(&xprt->binding, task, in rpcb_getport_async()
666 NULL, jiffies + xprt->bind_timeout); in rpcb_getport_async()
668 if (xprt_test_and_set_binding(xprt)) { in rpcb_getport_async()
669 xprt_put(xprt); in rpcb_getport_async()
674 if (xprt_bound(xprt)) { in rpcb_getport_async()
[all …]
Dsvcsock.c350 static int svc_tcp_has_wspace(struct svc_xprt *xprt) in svc_tcp_has_wspace() argument
352 struct svc_sock *svsk = container_of(xprt, struct svc_sock, sk_xprt); in svc_tcp_has_wspace()
354 if (test_bit(XPT_LISTENER, &xprt->xpt_flags)) in svc_tcp_has_wspace()
359 static void svc_tcp_kill_temp_xprt(struct svc_xprt *xprt) in svc_tcp_kill_temp_xprt() argument
361 struct svc_sock *svsk = container_of(xprt, struct svc_sock, sk_xprt); in svc_tcp_kill_temp_xprt()
553 struct svc_xprt *xprt = rqstp->rq_xprt; in svc_udp_sendto() local
554 struct svc_sock *svsk = container_of(xprt, struct svc_sock, sk_xprt); in svc_udp_sendto()
574 mutex_lock(&xprt->xpt_mutex); in svc_udp_sendto()
576 if (svc_xprt_is_dead(xprt)) in svc_udp_sendto()
586 trace_svcsock_udp_send(xprt, err); in svc_udp_sendto()
[all …]
Dsvcauth_unix.c345 ip_map_cached_get(struct svc_xprt *xprt) in ip_map_cached_get() argument
350 if (test_bit(XPT_CACHE_AUTH, &xprt->xpt_flags)) { in ip_map_cached_get()
351 spin_lock(&xprt->xpt_lock); in ip_map_cached_get()
352 ipm = xprt->xpt_auth_cache; in ip_map_cached_get()
354 sn = net_generic(xprt->xpt_net, sunrpc_net_id); in ip_map_cached_get()
361 xprt->xpt_auth_cache = NULL; in ip_map_cached_get()
362 spin_unlock(&xprt->xpt_lock); in ip_map_cached_get()
368 spin_unlock(&xprt->xpt_lock); in ip_map_cached_get()
374 ip_map_cached_put(struct svc_xprt *xprt, struct ip_map *ipm) in ip_map_cached_put() argument
376 if (test_bit(XPT_CACHE_AUTH, &xprt->xpt_flags)) { in ip_map_cached_put()
[all …]
/kernel/linux/linux-5.10/include/linux/sunrpc/
Dxprt.h30 #define RPC_MAXCWND(xprt) ((xprt)->max_reqs << RPC_CWNDSHIFT) argument
31 #define RPCXPRT_CONGESTED(xprt) ((xprt)->cong >= (xprt)->cwnd) argument
132 void (*set_buffer_size)(struct rpc_xprt *xprt, size_t sndsize, size_t rcvsize);
133 int (*reserve_xprt)(struct rpc_xprt *xprt, struct rpc_task *task);
134 void (*release_xprt)(struct rpc_xprt *xprt, struct rpc_task *task);
135 void (*alloc_slot)(struct rpc_xprt *xprt, struct rpc_task *task);
136 void (*free_slot)(struct rpc_xprt *xprt,
139 void (*set_port)(struct rpc_xprt *xprt, unsigned short port);
140 void (*connect)(struct rpc_xprt *xprt, struct rpc_task *task);
146 void (*timer)(struct rpc_xprt *xprt, struct rpc_task *task);
[all …]
Dsvc_xprt.h120 static inline bool svc_xprt_is_dead(const struct svc_xprt *xprt) in svc_xprt_is_dead() argument
122 return (test_bit(XPT_DEAD, &xprt->xpt_flags) != 0) || in svc_xprt_is_dead()
123 (test_bit(XPT_CLOSE, &xprt->xpt_flags) != 0); in svc_xprt_is_dead()
133 void svc_xprt_do_enqueue(struct svc_xprt *xprt);
134 void svc_xprt_enqueue(struct svc_xprt *xprt);
135 void svc_xprt_put(struct svc_xprt *xprt);
136 void svc_xprt_copy_addrs(struct svc_rqst *rqstp, struct svc_xprt *xprt);
137 void svc_close_xprt(struct svc_xprt *xprt);
144 void svc_add_new_perm_xprt(struct svc_serv *serv, struct svc_xprt *xprt);
147 static inline void svc_xprt_get(struct svc_xprt *xprt) in svc_xprt_get() argument
[all …]
Dbc_xprt.h35 struct rpc_rqst *xprt_lookup_bc_request(struct rpc_xprt *xprt, __be32 xid);
43 int xprt_setup_bc(struct rpc_xprt *xprt, unsigned int min_reqs);
44 void xprt_destroy_bc(struct rpc_xprt *xprt, unsigned int max_reqs);
46 unsigned int xprt_bc_max_slots(struct rpc_xprt *xprt);
61 static inline int xprt_setup_backchannel(struct rpc_xprt *xprt, in xprt_setup_backchannel() argument
67 static inline void xprt_destroy_backchannel(struct rpc_xprt *xprt, in xprt_destroy_backchannel() argument
Dxprtmultipath.h43 extern struct rpc_xprt_switch *xprt_switch_alloc(struct rpc_xprt *xprt,
52 struct rpc_xprt *xprt);
54 struct rpc_xprt *xprt);
Ddebug.h118 rpc_xprt_debugfs_register(struct rpc_xprt *xprt) in rpc_xprt_debugfs_register() argument
124 rpc_xprt_debugfs_unregister(struct rpc_xprt *xprt) in rpc_xprt_debugfs_unregister() argument
Dclnt.h140 struct rpc_xprt *xprt,
173 struct rpc_xprt *xprt);
214 struct rpc_xprt *xprt,
/kernel/linux/linux-5.10/net/sunrpc/xprtrdma/
Dtransport.c160 xprt_rdma_format_addresses4(struct rpc_xprt *xprt, struct sockaddr *sap) in xprt_rdma_format_addresses4() argument
166 xprt->address_strings[RPC_DISPLAY_HEX_ADDR] = kstrdup(buf, GFP_KERNEL); in xprt_rdma_format_addresses4()
168 xprt->address_strings[RPC_DISPLAY_NETID] = RPCBIND_NETID_RDMA; in xprt_rdma_format_addresses4()
172 xprt_rdma_format_addresses6(struct rpc_xprt *xprt, struct sockaddr *sap) in xprt_rdma_format_addresses6() argument
178 xprt->address_strings[RPC_DISPLAY_HEX_ADDR] = kstrdup(buf, GFP_KERNEL); in xprt_rdma_format_addresses6()
180 xprt->address_strings[RPC_DISPLAY_NETID] = RPCBIND_NETID_RDMA6; in xprt_rdma_format_addresses6()
184 xprt_rdma_format_addresses(struct rpc_xprt *xprt, struct sockaddr *sap) in xprt_rdma_format_addresses() argument
190 xprt_rdma_format_addresses4(xprt, sap); in xprt_rdma_format_addresses()
193 xprt_rdma_format_addresses6(xprt, sap); in xprt_rdma_format_addresses()
201 xprt->address_strings[RPC_DISPLAY_ADDR] = kstrdup(buf, GFP_KERNEL); in xprt_rdma_format_addresses()
[all …]
Dsvc_rdma_backchannel.c23 struct rpc_xprt *xprt = sxprt->xpt_bc_xprt; in svc_rdma_handle_bc_reply() local
24 struct rpcrdma_xprt *r_xprt = rpcx_to_rdmax(xprt); in svc_rdma_handle_bc_reply()
31 spin_lock(&xprt->queue_lock); in svc_rdma_handle_bc_reply()
32 req = xprt_lookup_rqst(xprt, *rdma_resp); in svc_rdma_handle_bc_reply()
42 spin_unlock(&xprt->queue_lock); in svc_rdma_handle_bc_reply()
49 spin_lock(&xprt->transport_lock); in svc_rdma_handle_bc_reply()
50 xprt->cwnd = credits << RPC_CWNDSHIFT; in svc_rdma_handle_bc_reply()
51 spin_unlock(&xprt->transport_lock); in svc_rdma_handle_bc_reply()
53 spin_lock(&xprt->queue_lock); in svc_rdma_handle_bc_reply()
59 spin_unlock(&xprt->queue_lock); in svc_rdma_handle_bc_reply()
[all …]
Dbackchannel.c29 int xprt_rdma_bc_setup(struct rpc_xprt *xprt, unsigned int reqs) in xprt_rdma_bc_setup() argument
31 struct rpcrdma_xprt *r_xprt = rpcx_to_rdmax(xprt); in xprt_rdma_bc_setup()
44 size_t xprt_rdma_bc_maxpayload(struct rpc_xprt *xprt) in xprt_rdma_bc_maxpayload() argument
46 struct rpcrdma_xprt *r_xprt = rpcx_to_rdmax(xprt); in xprt_rdma_bc_maxpayload()
55 unsigned int xprt_rdma_bc_max_slots(struct rpc_xprt *xprt) in xprt_rdma_bc_max_slots() argument
103 struct rpc_xprt *xprt = rqst->rq_xprt; in xprt_rdma_bc_send_reply() local
104 struct rpcrdma_xprt *r_xprt = rpcx_to_rdmax(xprt); in xprt_rdma_bc_send_reply()
108 if (!xprt_connected(xprt)) in xprt_rdma_bc_send_reply()
111 if (!xprt_request_get_cong(xprt, rqst)) in xprt_rdma_bc_send_reply()
126 xprt_rdma_close(xprt); in xprt_rdma_bc_send_reply()
[all …]
Dsvc_rdma_transport.c72 static struct svc_xprt *svc_rdma_accept(struct svc_xprt *xprt);
73 static void svc_rdma_detach(struct svc_xprt *xprt);
74 static void svc_rdma_free(struct svc_xprt *xprt);
75 static int svc_rdma_has_wspace(struct svc_xprt *xprt);
104 struct svc_xprt *xprt = context; in qp_event_handler() local
106 trace_svcrdma_qp_error(event, (struct sockaddr *)&xprt->xpt_remote); in qp_event_handler()
122 set_bit(XPT_CLOSE, &xprt->xpt_flags); in qp_event_handler()
123 svc_xprt_enqueue(xprt); in qp_event_handler()
277 struct svc_xprt *xprt = &rdma->sc_xprt; in svc_rdma_cma_handler() local
282 svc_xprt_enqueue(xprt); in svc_rdma_cma_handler()
[all …]
Drpc_rdma.c1003 static void __rpcrdma_update_cwnd_locked(struct rpc_xprt *xprt, in __rpcrdma_update_cwnd_locked() argument
1008 xprt->cwnd = grant << RPC_CWNDSHIFT; in __rpcrdma_update_cwnd_locked()
1013 struct rpc_xprt *xprt = &r_xprt->rx_xprt; in rpcrdma_update_cwnd() local
1015 spin_lock(&xprt->transport_lock); in rpcrdma_update_cwnd()
1016 __rpcrdma_update_cwnd_locked(xprt, &r_xprt->rx_buf, grant); in rpcrdma_update_cwnd()
1017 spin_unlock(&xprt->transport_lock); in rpcrdma_update_cwnd()
1029 struct rpc_xprt *xprt = &r_xprt->rx_xprt; in rpcrdma_reset_cwnd() local
1031 spin_lock(&xprt->transport_lock); in rpcrdma_reset_cwnd()
1032 xprt->cong = 0; in rpcrdma_reset_cwnd()
1033 __rpcrdma_update_cwnd_locked(xprt, &r_xprt->rx_buf, 1); in rpcrdma_reset_cwnd()
[all …]
Dsvc_rdma_recvfrom.c246 struct svc_xprt *xprt = rqstp->rq_xprt; in svc_rdma_release_rqst() local
248 container_of(xprt, struct svcxprt_rdma, sc_xprt); in svc_rdma_release_rqst()
738 static bool svc_rdma_is_backchannel_reply(struct svc_xprt *xprt, in svc_rdma_is_backchannel_reply() argument
743 if (!xprt->xpt_bc_xprt) in svc_rdma_is_backchannel_reply()
799 struct svc_xprt *xprt = rqstp->rq_xprt; in svc_rdma_recvfrom() local
801 container_of(xprt, struct svcxprt_rdma, sc_xprt); in svc_rdma_recvfrom()
819 clear_bit(XPT_DATA, &xprt->xpt_flags); in svc_rdma_recvfrom()
844 if (svc_rdma_is_backchannel_reply(xprt, p)) in svc_rdma_recvfrom()
856 svc_xprt_copy_addrs(rqstp, xprt); in svc_rdma_recvfrom()
Dxprt_rdma.h568 void xprt_rdma_format_addresses(struct rpc_xprt *xprt, struct sockaddr *sap);
569 void xprt_rdma_free_addresses(struct rpc_xprt *xprt);
570 void xprt_rdma_close(struct rpc_xprt *xprt);
571 void xprt_rdma_print_stats(struct rpc_xprt *xprt, struct seq_file *seq);
/kernel/linux/linux-5.10/include/trace/events/
Dsunrpc.h138 const struct rpc_xprt *xprt,
143 TP_ARGS(clnt, xprt, program, server),
147 __string(addr, xprt->address_strings[RPC_DISPLAY_ADDR])
148 __string(port, xprt->address_strings[RPC_DISPLAY_PORT])
155 __assign_str(addr, xprt->address_strings[RPC_DISPLAY_ADDR]);
156 __assign_str(port, xprt->address_strings[RPC_DISPLAY_PORT]);
815 struct rpc_xprt *xprt,
819 TP_ARGS(xprt, socket),
826 xprt->address_strings[RPC_DISPLAY_ADDR])
828 xprt->address_strings[RPC_DISPLAY_PORT])
[all …]
/kernel/linux/linux-5.10/fs/nfs/
Dcallback.c144 static inline void nfs_callback_bc_serv(u32 minorversion, struct rpc_xprt *xprt, in nfs_callback_bc_serv() argument
152 xprt->bc_serv = serv; in nfs_callback_bc_serv()
155 static inline void nfs_callback_bc_serv(u32 minorversion, struct rpc_xprt *xprt, in nfs_callback_bc_serv() argument
161 static int nfs_callback_start_svc(int minorversion, struct rpc_xprt *xprt, in nfs_callback_start_svc() argument
167 nfs_callback_bc_serv(minorversion, xprt, serv); in nfs_callback_start_svc()
196 struct net *net, struct rpc_xprt *xprt) in nfs_callback_up_net() argument
215 else if (xprt->ops->bc_setup) in nfs_callback_up_net()
314 int nfs_callback_up(u32 minorversion, struct rpc_xprt *xprt) in nfs_callback_up() argument
319 struct net *net = xprt->xprt_net; in nfs_callback_up()
329 ret = nfs_callback_up_net(minorversion, serv, net, xprt); in nfs_callback_up()
[all …]

12