Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 229215
b: refs/heads/master
c: 16b2d1e
h: refs/heads/master
i:
  229213: 7d2ed87
  229211: 32bfae2
  229207: 5e75c78
  229199: 57ea717
  229183: b674bad
v: v3
  • Loading branch information
Andy Adamson authored and Trond Myklebust committed Jan 6, 2011
1 parent 57a59f3 commit abe69e7
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 1f11a034cdc4b45ee56d51b87a9e37cb776fb15b
refs/heads/master: 16b2d1e1d12de000404d7c845d0db1226511f84d
1 change: 0 additions & 1 deletion trunk/include/linux/sunrpc/svcsock.h
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,6 @@ int svc_sock_names(struct svc_serv *serv, char *buf,
int svc_addsock(struct svc_serv *serv, const int fd,
char *name_return, const size_t len);
void svc_init_xprt_sock(void);
void svc_init_bc_xprt_sock(void);
void svc_cleanup_xprt_sock(void);
struct svc_xprt *svc_sock_create(struct svc_serv *serv, int prot);
void svc_sock_destroy(struct svc_xprt *);
Expand Down
20 changes: 20 additions & 0 deletions trunk/net/sunrpc/svcsock.c
Original file line number Diff line number Diff line change
Expand Up @@ -1222,6 +1222,24 @@ static struct svc_xprt_class svc_tcp_bc_class = {
.xcl_ops = &svc_tcp_bc_ops,
.xcl_max_payload = RPCSVC_MAXPAYLOAD_TCP,
};

static void svc_init_bc_xprt_sock(void)
{
svc_reg_xprt_class(&svc_tcp_bc_class);
}

static void svc_cleanup_bc_xprt_sock(void)
{
svc_unreg_xprt_class(&svc_tcp_bc_class);
}
#else /* CONFIG_NFS_V4_1 */
static void svc_init_bc_xprt_sock(void)
{
}

static void svc_cleanup_bc_xprt_sock(void)
{
}
#endif /* CONFIG_NFS_V4_1 */

static struct svc_xprt_ops svc_tcp_ops = {
Expand All @@ -1247,12 +1265,14 @@ void svc_init_xprt_sock(void)
{
svc_reg_xprt_class(&svc_tcp_class);
svc_reg_xprt_class(&svc_udp_class);
svc_init_bc_xprt_sock();
}

void svc_cleanup_xprt_sock(void)
{
svc_unreg_xprt_class(&svc_tcp_class);
svc_unreg_xprt_class(&svc_udp_class);
svc_cleanup_bc_xprt_sock();
}

static void svc_tcp_init(struct svc_sock *svsk, struct svc_serv *serv)
Expand Down

0 comments on commit abe69e7

Please sign in to comment.