Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 153659
b: refs/heads/master
c: bfba9ab
h: refs/heads/master
i:
  153657: 5ff8de4
  153655: 52ce6c1
v: v3
  • Loading branch information
Chuck Lever authored and J. Bruce Fields committed Apr 28, 2009
1 parent a6b9a0f commit b11163f
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 6 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: 335c54bdc4d3bacdbd619ec95cd0b352435bd37f
refs/heads/master: bfba9ab4c64f0e5c33930711e6c073c285e01fcf
2 changes: 1 addition & 1 deletion trunk/fs/nfsd/nfsctl.c
Original file line number Diff line number Diff line change
Expand Up @@ -943,7 +943,7 @@ static ssize_t __write_ports_addfd(char *buf)
if (err != 0)
goto out;

err = svc_addsock(nfsd_serv, fd, buf);
err = svc_addsock(nfsd_serv, fd, buf, SIMPLE_TRANSACTION_LIMIT);
if (err < 0)
lockd_down();

Expand Down
3 changes: 2 additions & 1 deletion trunk/include/linux/sunrpc/svcsock.h
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,8 @@ int svc_send(struct svc_rqst *);
void svc_drop(struct svc_rqst *);
void svc_sock_update_bufs(struct svc_serv *serv);
int svc_sock_names(char *buf, struct svc_serv *serv, char *toclose);
int svc_addsock(struct svc_serv *serv, int fd, char *name_return);
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_cleanup_xprt_sock(void);

Expand Down
16 changes: 13 additions & 3 deletions trunk/net/sunrpc/svcsock.c
Original file line number Diff line number Diff line change
Expand Up @@ -1128,9 +1128,19 @@ static struct svc_sock *svc_setup_socket(struct svc_serv *serv,
return svsk;
}

int svc_addsock(struct svc_serv *serv,
int fd,
char *name_return)
/**
* svc_addsock - add a listener socket to an RPC service
* @serv: pointer to RPC service to which to add a new listener
* @fd: file descriptor of the new listener
* @name_return: pointer to buffer to fill in with name of listener
* @len: size of the buffer
*
* Fills in socket name and returns positive length of name if successful.
* Name is terminated with '\n'. On error, returns a negative errno
* value.
*/
int svc_addsock(struct svc_serv *serv, const int fd, char *name_return,
const size_t len)
{
int err = 0;
struct socket *so = sockfd_lookup(fd, &err);
Expand Down

0 comments on commit b11163f

Please sign in to comment.