NLM: Remove unused argument from svc_addsock() function
authorChuck Lever <chuck.lever@oracle.com>
Fri, 3 Oct 2008 21:15:38 +0000 (17:15 -0400)
committerJ. Bruce Fields <bfields@citi.umich.edu>
Sat, 4 Oct 2008 21:12:27 +0000 (17:12 -0400)
Clean up: The svc_addsock() function no longer uses its "proto"
argument, so remove it.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Cc: Neil Brown <neilb@suse.de>
Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu>
fs/nfsd/nfsctl.c
include/linux/sunrpc/svcsock.h
net/sunrpc/svcsock.c

index 862dff5247f7e797205fa37e77424f62c00169f8..97543df58242f1bc54244aeac633a4fc2e139c8f 100644 (file)
@@ -614,7 +614,7 @@ static ssize_t __write_ports(struct file *file, char *buf, size_t size)
                        return -EINVAL;
                err = nfsd_create_serv();
                if (!err) {
-                       err = svc_addsock(nfsd_serv, fd, buf, NULL);
+                       err = svc_addsock(nfsd_serv, fd, buf);
                        if (err >= 0) {
                                err = lockd_up();
                                if (err < 0)
index 8cff696dedf58413dac70ab00294c19ba898bcba..483e10380aae45429b8ad7aba5a930aa8e4f3695 100644 (file)
@@ -39,10 +39,7 @@ 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 *proto);
+int            svc_addsock(struct svc_serv *serv, int fd, char *name_return);
 void           svc_init_xprt_sock(void);
 void           svc_cleanup_xprt_sock(void);
 
index f91377c149510d1e692673a7febd0ed2e207d8fc..95293f549e9c2b371b82ce32af4ca43be00b5ada 100644 (file)
@@ -1167,8 +1167,7 @@ static struct svc_sock *svc_setup_socket(struct svc_serv *serv,
 
 int svc_addsock(struct svc_serv *serv,
                int fd,
-               char *name_return,
-               int *proto)
+               char *name_return)
 {
        int err = 0;
        struct socket *so = sockfd_lookup(fd, &err);
@@ -1203,7 +1202,6 @@ int svc_addsock(struct svc_serv *serv,
                sockfd_put(so);
                return err;
        }
-       if (proto) *proto = so->sk->sk_protocol;
        return one_sock_name(name_return, svsk);
 }
 EXPORT_SYMBOL_GPL(svc_addsock);