diff options
Diffstat (limited to 'fs/lockd')
-rw-r--r-- | fs/lockd/svc.c | 16 |
1 files changed, 2 insertions, 14 deletions
diff --git a/fs/lockd/svc.c b/fs/lockd/svc.c index a8e79a907202..470af0138bb5 100644 --- a/fs/lockd/svc.c +++ b/fs/lockd/svc.c | |||
@@ -219,18 +219,6 @@ lockd(struct svc_rqst *rqstp) | |||
219 | module_put_and_exit(0); | 219 | module_put_and_exit(0); |
220 | } | 220 | } |
221 | 221 | ||
222 | static int find_xprt(struct svc_serv *serv, char *proto) | ||
223 | { | ||
224 | struct svc_xprt *xprt; | ||
225 | int found = 0; | ||
226 | list_for_each_entry(xprt, &serv->sv_permsocks, xpt_list) | ||
227 | if (strcmp(xprt->xpt_class->xcl_name, proto) == 0) { | ||
228 | found = 1; | ||
229 | break; | ||
230 | } | ||
231 | return found; | ||
232 | } | ||
233 | |||
234 | /* | 222 | /* |
235 | * Make any sockets that are needed but not present. | 223 | * Make any sockets that are needed but not present. |
236 | * If nlm_udpport or nlm_tcpport were set as module | 224 | * If nlm_udpport or nlm_tcpport were set as module |
@@ -242,11 +230,11 @@ static int make_socks(struct svc_serv *serv, int proto) | |||
242 | int err = 0; | 230 | int err = 0; |
243 | 231 | ||
244 | if (proto == IPPROTO_UDP || nlm_udpport) | 232 | if (proto == IPPROTO_UDP || nlm_udpport) |
245 | if (!find_xprt(serv, "udp")) | 233 | if (!svc_find_xprt(serv, "udp", 0, 0)) |
246 | err = svc_create_xprt(serv, "udp", nlm_udpport, | 234 | err = svc_create_xprt(serv, "udp", nlm_udpport, |
247 | SVC_SOCK_DEFAULTS); | 235 | SVC_SOCK_DEFAULTS); |
248 | if (err >= 0 && (proto == IPPROTO_TCP || nlm_tcpport)) | 236 | if (err >= 0 && (proto == IPPROTO_TCP || nlm_tcpport)) |
249 | if (!find_xprt(serv, "tcp")) | 237 | if (!svc_find_xprt(serv, "tcp", 0, 0)) |
250 | err = svc_create_xprt(serv, "tcp", nlm_tcpport, | 238 | err = svc_create_xprt(serv, "tcp", nlm_tcpport, |
251 | SVC_SOCK_DEFAULTS); | 239 | SVC_SOCK_DEFAULTS); |
252 | 240 | ||