diff options
Diffstat (limited to 'fs/lockd/svc.c')
-rw-r--r-- | fs/lockd/svc.c | 29 |
1 files changed, 9 insertions, 20 deletions
diff --git a/fs/lockd/svc.c b/fs/lockd/svc.c index 1a54ae14a192..f1bacf1a0391 100644 --- a/fs/lockd/svc.c +++ b/fs/lockd/svc.c | |||
@@ -21,7 +21,6 @@ | |||
21 | #include <linux/errno.h> | 21 | #include <linux/errno.h> |
22 | #include <linux/in.h> | 22 | #include <linux/in.h> |
23 | #include <linux/uio.h> | 23 | #include <linux/uio.h> |
24 | #include <linux/slab.h> | ||
25 | #include <linux/smp.h> | 24 | #include <linux/smp.h> |
26 | #include <linux/smp_lock.h> | 25 | #include <linux/smp_lock.h> |
27 | #include <linux/mutex.h> | 26 | #include <linux/mutex.h> |
@@ -243,11 +242,9 @@ static int make_socks(struct svc_serv *serv) | |||
243 | if (err < 0) | 242 | if (err < 0) |
244 | goto out_err; | 243 | goto out_err; |
245 | 244 | ||
246 | #if defined(CONFIG_IPV6) || defined(CONFIG_IPV6_MODULE) | ||
247 | err = create_lockd_family(serv, PF_INET6); | 245 | err = create_lockd_family(serv, PF_INET6); |
248 | if (err < 0 && err != -EAFNOSUPPORT) | 246 | if (err < 0 && err != -EAFNOSUPPORT) |
249 | goto out_err; | 247 | goto out_err; |
250 | #endif /* CONFIG_IPV6 || CONFIG_IPV6_MODULE */ | ||
251 | 248 | ||
252 | warned = 0; | 249 | warned = 0; |
253 | return 0; | 250 | return 0; |
@@ -371,82 +368,74 @@ EXPORT_SYMBOL_GPL(lockd_down); | |||
371 | 368 | ||
372 | static ctl_table nlm_sysctls[] = { | 369 | static ctl_table nlm_sysctls[] = { |
373 | { | 370 | { |
374 | .ctl_name = CTL_UNNUMBERED, | ||
375 | .procname = "nlm_grace_period", | 371 | .procname = "nlm_grace_period", |
376 | .data = &nlm_grace_period, | 372 | .data = &nlm_grace_period, |
377 | .maxlen = sizeof(unsigned long), | 373 | .maxlen = sizeof(unsigned long), |
378 | .mode = 0644, | 374 | .mode = 0644, |
379 | .proc_handler = &proc_doulongvec_minmax, | 375 | .proc_handler = proc_doulongvec_minmax, |
380 | .extra1 = (unsigned long *) &nlm_grace_period_min, | 376 | .extra1 = (unsigned long *) &nlm_grace_period_min, |
381 | .extra2 = (unsigned long *) &nlm_grace_period_max, | 377 | .extra2 = (unsigned long *) &nlm_grace_period_max, |
382 | }, | 378 | }, |
383 | { | 379 | { |
384 | .ctl_name = CTL_UNNUMBERED, | ||
385 | .procname = "nlm_timeout", | 380 | .procname = "nlm_timeout", |
386 | .data = &nlm_timeout, | 381 | .data = &nlm_timeout, |
387 | .maxlen = sizeof(unsigned long), | 382 | .maxlen = sizeof(unsigned long), |
388 | .mode = 0644, | 383 | .mode = 0644, |
389 | .proc_handler = &proc_doulongvec_minmax, | 384 | .proc_handler = proc_doulongvec_minmax, |
390 | .extra1 = (unsigned long *) &nlm_timeout_min, | 385 | .extra1 = (unsigned long *) &nlm_timeout_min, |
391 | .extra2 = (unsigned long *) &nlm_timeout_max, | 386 | .extra2 = (unsigned long *) &nlm_timeout_max, |
392 | }, | 387 | }, |
393 | { | 388 | { |
394 | .ctl_name = CTL_UNNUMBERED, | ||
395 | .procname = "nlm_udpport", | 389 | .procname = "nlm_udpport", |
396 | .data = &nlm_udpport, | 390 | .data = &nlm_udpport, |
397 | .maxlen = sizeof(int), | 391 | .maxlen = sizeof(int), |
398 | .mode = 0644, | 392 | .mode = 0644, |
399 | .proc_handler = &proc_dointvec_minmax, | 393 | .proc_handler = proc_dointvec_minmax, |
400 | .extra1 = (int *) &nlm_port_min, | 394 | .extra1 = (int *) &nlm_port_min, |
401 | .extra2 = (int *) &nlm_port_max, | 395 | .extra2 = (int *) &nlm_port_max, |
402 | }, | 396 | }, |
403 | { | 397 | { |
404 | .ctl_name = CTL_UNNUMBERED, | ||
405 | .procname = "nlm_tcpport", | 398 | .procname = "nlm_tcpport", |
406 | .data = &nlm_tcpport, | 399 | .data = &nlm_tcpport, |
407 | .maxlen = sizeof(int), | 400 | .maxlen = sizeof(int), |
408 | .mode = 0644, | 401 | .mode = 0644, |
409 | .proc_handler = &proc_dointvec_minmax, | 402 | .proc_handler = proc_dointvec_minmax, |
410 | .extra1 = (int *) &nlm_port_min, | 403 | .extra1 = (int *) &nlm_port_min, |
411 | .extra2 = (int *) &nlm_port_max, | 404 | .extra2 = (int *) &nlm_port_max, |
412 | }, | 405 | }, |
413 | { | 406 | { |
414 | .ctl_name = CTL_UNNUMBERED, | ||
415 | .procname = "nsm_use_hostnames", | 407 | .procname = "nsm_use_hostnames", |
416 | .data = &nsm_use_hostnames, | 408 | .data = &nsm_use_hostnames, |
417 | .maxlen = sizeof(int), | 409 | .maxlen = sizeof(int), |
418 | .mode = 0644, | 410 | .mode = 0644, |
419 | .proc_handler = &proc_dointvec, | 411 | .proc_handler = proc_dointvec, |
420 | }, | 412 | }, |
421 | { | 413 | { |
422 | .ctl_name = CTL_UNNUMBERED, | ||
423 | .procname = "nsm_local_state", | 414 | .procname = "nsm_local_state", |
424 | .data = &nsm_local_state, | 415 | .data = &nsm_local_state, |
425 | .maxlen = sizeof(int), | 416 | .maxlen = sizeof(int), |
426 | .mode = 0644, | 417 | .mode = 0644, |
427 | .proc_handler = &proc_dointvec, | 418 | .proc_handler = proc_dointvec, |
428 | }, | 419 | }, |
429 | { .ctl_name = 0 } | 420 | { } |
430 | }; | 421 | }; |
431 | 422 | ||
432 | static ctl_table nlm_sysctl_dir[] = { | 423 | static ctl_table nlm_sysctl_dir[] = { |
433 | { | 424 | { |
434 | .ctl_name = CTL_UNNUMBERED, | ||
435 | .procname = "nfs", | 425 | .procname = "nfs", |
436 | .mode = 0555, | 426 | .mode = 0555, |
437 | .child = nlm_sysctls, | 427 | .child = nlm_sysctls, |
438 | }, | 428 | }, |
439 | { .ctl_name = 0 } | 429 | { } |
440 | }; | 430 | }; |
441 | 431 | ||
442 | static ctl_table nlm_sysctl_root[] = { | 432 | static ctl_table nlm_sysctl_root[] = { |
443 | { | 433 | { |
444 | .ctl_name = CTL_FS, | ||
445 | .procname = "fs", | 434 | .procname = "fs", |
446 | .mode = 0555, | 435 | .mode = 0555, |
447 | .child = nlm_sysctl_dir, | 436 | .child = nlm_sysctl_dir, |
448 | }, | 437 | }, |
449 | { .ctl_name = 0 } | 438 | { } |
450 | }; | 439 | }; |
451 | 440 | ||
452 | #endif /* CONFIG_SYSCTL */ | 441 | #endif /* CONFIG_SYSCTL */ |