NFS: Enable client side NFSv4.1 backchannel to use other transports
Forechannel transports get their own "bc_up" method to create an endpoint for the backchannel service. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> [Anna Schumaker: Add forward declaration of struct net to xprt.h] Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
This commit is contained in:

committed by
Anna Schumaker

parent
0f2e3bdab6
commit
76566773a1
@@ -1306,6 +1306,17 @@ static inline int _xs_tcp_read_data(struct rpc_xprt *xprt,
|
||||
xs_tcp_read_reply(xprt, desc) :
|
||||
xs_tcp_read_callback(xprt, desc);
|
||||
}
|
||||
|
||||
static int xs_tcp_bc_up(struct svc_serv *serv, struct net *net)
|
||||
{
|
||||
int ret;
|
||||
|
||||
ret = svc_create_xprt(serv, "tcp-bc", net, PF_INET, 0,
|
||||
SVC_SOCK_ANONYMOUS);
|
||||
if (ret < 0)
|
||||
return ret;
|
||||
return 0;
|
||||
}
|
||||
#else
|
||||
static inline int _xs_tcp_read_data(struct rpc_xprt *xprt,
|
||||
struct xdr_skb_reader *desc)
|
||||
@@ -2582,6 +2593,7 @@ static struct rpc_xprt_ops xs_tcp_ops = {
|
||||
.inject_disconnect = xs_inject_disconnect,
|
||||
#ifdef CONFIG_SUNRPC_BACKCHANNEL
|
||||
.bc_setup = xprt_setup_bc,
|
||||
.bc_up = xs_tcp_bc_up,
|
||||
.bc_free_rqst = xprt_free_bc_rqst,
|
||||
.bc_destroy = xprt_destroy_bc,
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user