diff options
| author | Jeff Garzik <jgarzik@pobox.com> | 2005-08-10 13:46:28 -0400 |
|---|---|---|
| committer | Jeff Garzik <jgarzik@pobox.com> | 2005-08-10 13:46:28 -0400 |
| commit | 2f058256cb64e346f4fb4499ff4e0f1c2791a4b4 (patch) | |
| tree | 91e06602f4d3abb6812ea8c9bc9ba4501e14c84e /kernel/sysctl.c | |
| parent | 0274aa2506fd2fe89a58dd6cd64d3b3f7b976af8 (diff) | |
| parent | 86b3786078d63242d3194ffc58ae8dae1d1bbef3 (diff) | |
Merge /spare/repo/linux-2.6/
Diffstat (limited to 'kernel/sysctl.c')
| -rw-r--r-- | kernel/sysctl.c | 38 |
1 files changed, 34 insertions, 4 deletions
diff --git a/kernel/sysctl.c b/kernel/sysctl.c index 701d12c63068..3e0bbee549ea 100644 --- a/kernel/sysctl.c +++ b/kernel/sysctl.c | |||
| @@ -58,6 +58,7 @@ extern int sysctl_overcommit_ratio; | |||
| 58 | extern int max_threads; | 58 | extern int max_threads; |
| 59 | extern int sysrq_enabled; | 59 | extern int sysrq_enabled; |
| 60 | extern int core_uses_pid; | 60 | extern int core_uses_pid; |
| 61 | extern int suid_dumpable; | ||
| 61 | extern char core_pattern[]; | 62 | extern char core_pattern[]; |
| 62 | extern int cad_pid; | 63 | extern int cad_pid; |
| 63 | extern int pid_max; | 64 | extern int pid_max; |
| @@ -113,6 +114,7 @@ extern int unaligned_enabled; | |||
| 113 | extern int sysctl_ieee_emulation_warnings; | 114 | extern int sysctl_ieee_emulation_warnings; |
| 114 | #endif | 115 | #endif |
| 115 | extern int sysctl_userprocess_debug; | 116 | extern int sysctl_userprocess_debug; |
| 117 | extern int spin_retry; | ||
| 116 | #endif | 118 | #endif |
| 117 | 119 | ||
| 118 | extern int sysctl_hz_timer; | 120 | extern int sysctl_hz_timer; |
| @@ -145,6 +147,9 @@ extern ctl_table random_table[]; | |||
| 145 | #ifdef CONFIG_UNIX98_PTYS | 147 | #ifdef CONFIG_UNIX98_PTYS |
| 146 | extern ctl_table pty_table[]; | 148 | extern ctl_table pty_table[]; |
| 147 | #endif | 149 | #endif |
| 150 | #ifdef CONFIG_INOTIFY | ||
| 151 | extern ctl_table inotify_table[]; | ||
| 152 | #endif | ||
| 148 | 153 | ||
| 149 | #ifdef HAVE_ARCH_PICK_MMAP_LAYOUT | 154 | #ifdef HAVE_ARCH_PICK_MMAP_LAYOUT |
| 150 | int sysctl_legacy_va_layout; | 155 | int sysctl_legacy_va_layout; |
| @@ -217,6 +222,7 @@ static ctl_table root_table[] = { | |||
| 217 | .mode = 0555, | 222 | .mode = 0555, |
| 218 | .child = dev_table, | 223 | .child = dev_table, |
| 219 | }, | 224 | }, |
| 225 | |||
| 220 | { .ctl_name = 0 } | 226 | { .ctl_name = 0 } |
| 221 | }; | 227 | }; |
| 222 | 228 | ||
| @@ -642,7 +648,16 @@ static ctl_table kern_table[] = { | |||
| 642 | .mode = 0644, | 648 | .mode = 0644, |
| 643 | .proc_handler = &proc_dointvec, | 649 | .proc_handler = &proc_dointvec, |
| 644 | }, | 650 | }, |
| 645 | 651 | #if defined(CONFIG_ARCH_S390) | |
| 652 | { | ||
| 653 | .ctl_name = KERN_SPIN_RETRY, | ||
| 654 | .procname = "spin_retry", | ||
| 655 | .data = &spin_retry, | ||
| 656 | .maxlen = sizeof (int), | ||
| 657 | .mode = 0644, | ||
| 658 | .proc_handler = &proc_dointvec, | ||
| 659 | }, | ||
| 660 | #endif | ||
| 646 | { .ctl_name = 0 } | 661 | { .ctl_name = 0 } |
| 647 | }; | 662 | }; |
| 648 | 663 | ||
| @@ -949,7 +964,23 @@ static ctl_table fs_table[] = { | |||
| 949 | .mode = 0644, | 964 | .mode = 0644, |
| 950 | .proc_handler = &proc_dointvec, | 965 | .proc_handler = &proc_dointvec, |
| 951 | }, | 966 | }, |
| 967 | #ifdef CONFIG_INOTIFY | ||
| 968 | { | ||
| 969 | .ctl_name = FS_INOTIFY, | ||
| 970 | .procname = "inotify", | ||
| 971 | .mode = 0555, | ||
| 972 | .child = inotify_table, | ||
| 973 | }, | ||
| 974 | #endif | ||
| 952 | #endif | 975 | #endif |
| 976 | { | ||
| 977 | .ctl_name = KERN_SETUID_DUMPABLE, | ||
| 978 | .procname = "suid_dumpable", | ||
| 979 | .data = &suid_dumpable, | ||
| 980 | .maxlen = sizeof(int), | ||
| 981 | .mode = 0644, | ||
| 982 | .proc_handler = &proc_dointvec, | ||
| 983 | }, | ||
| 953 | { .ctl_name = 0 } | 984 | { .ctl_name = 0 } |
| 954 | }; | 985 | }; |
| 955 | 986 | ||
| @@ -959,7 +990,7 @@ static ctl_table debug_table[] = { | |||
| 959 | 990 | ||
| 960 | static ctl_table dev_table[] = { | 991 | static ctl_table dev_table[] = { |
| 961 | { .ctl_name = 0 } | 992 | { .ctl_name = 0 } |
| 962 | }; | 993 | }; |
| 963 | 994 | ||
| 964 | extern void init_irq_proc (void); | 995 | extern void init_irq_proc (void); |
| 965 | 996 | ||
| @@ -991,8 +1022,7 @@ int do_sysctl(int __user *name, int nlen, void __user *oldval, size_t __user *ol | |||
| 991 | int error = parse_table(name, nlen, oldval, oldlenp, | 1022 | int error = parse_table(name, nlen, oldval, oldlenp, |
| 992 | newval, newlen, head->ctl_table, | 1023 | newval, newlen, head->ctl_table, |
| 993 | &context); | 1024 | &context); |
| 994 | if (context) | 1025 | kfree(context); |
| 995 | kfree(context); | ||
| 996 | if (error != -ENOTDIR) | 1026 | if (error != -ENOTDIR) |
| 997 | return error; | 1027 | return error; |
| 998 | tmp = tmp->next; | 1028 | tmp = tmp->next; |
