aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/sysctl.c
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/sysctl.c')
-rw-r--r--kernel/sysctl.c27
1 files changed, 11 insertions, 16 deletions
diff --git a/kernel/sysctl.c b/kernel/sysctl.c
index 6648fbbb8157..d9c31bc2eaea 100644
--- a/kernel/sysctl.c
+++ b/kernel/sysctl.c
@@ -367,7 +367,8 @@ static struct ctl_table kern_table[] = {
367 .data = &sysctl_sched_time_avg, 367 .data = &sysctl_sched_time_avg,
368 .maxlen = sizeof(unsigned int), 368 .maxlen = sizeof(unsigned int),
369 .mode = 0644, 369 .mode = 0644,
370 .proc_handler = proc_dointvec, 370 .proc_handler = proc_dointvec_minmax,
371 .extra1 = &one,
371 }, 372 },
372#ifdef CONFIG_SCHEDSTATS 373#ifdef CONFIG_SCHEDSTATS
373 { 374 {
@@ -871,9 +872,9 @@ static struct ctl_table kern_table[] = {
871#if defined(CONFIG_LOCKUP_DETECTOR) 872#if defined(CONFIG_LOCKUP_DETECTOR)
872 { 873 {
873 .procname = "watchdog", 874 .procname = "watchdog",
874 .data = &watchdog_user_enabled, 875 .data = &watchdog_user_enabled,
875 .maxlen = sizeof (int), 876 .maxlen = sizeof(int),
876 .mode = 0644, 877 .mode = 0644,
877 .proc_handler = proc_watchdog, 878 .proc_handler = proc_watchdog,
878 .extra1 = &zero, 879 .extra1 = &zero,
879 .extra2 = &one, 880 .extra2 = &one,
@@ -889,16 +890,12 @@ static struct ctl_table kern_table[] = {
889 }, 890 },
890 { 891 {
891 .procname = "nmi_watchdog", 892 .procname = "nmi_watchdog",
892 .data = &nmi_watchdog_enabled, 893 .data = &nmi_watchdog_user_enabled,
893 .maxlen = sizeof (int), 894 .maxlen = sizeof(int),
894 .mode = 0644, 895 .mode = NMI_WATCHDOG_SYSCTL_PERM,
895 .proc_handler = proc_nmi_watchdog, 896 .proc_handler = proc_nmi_watchdog,
896 .extra1 = &zero, 897 .extra1 = &zero,
897#if defined(CONFIG_HAVE_NMI_WATCHDOG) || defined(CONFIG_HARDLOCKUP_DETECTOR)
898 .extra2 = &one, 898 .extra2 = &one,
899#else
900 .extra2 = &zero,
901#endif
902 }, 899 },
903 { 900 {
904 .procname = "watchdog_cpumask", 901 .procname = "watchdog_cpumask",
@@ -910,9 +907,9 @@ static struct ctl_table kern_table[] = {
910#ifdef CONFIG_SOFTLOCKUP_DETECTOR 907#ifdef CONFIG_SOFTLOCKUP_DETECTOR
911 { 908 {
912 .procname = "soft_watchdog", 909 .procname = "soft_watchdog",
913 .data = &soft_watchdog_enabled, 910 .data = &soft_watchdog_user_enabled,
914 .maxlen = sizeof (int), 911 .maxlen = sizeof(int),
915 .mode = 0644, 912 .mode = 0644,
916 .proc_handler = proc_soft_watchdog, 913 .proc_handler = proc_soft_watchdog,
917 .extra1 = &zero, 914 .extra1 = &zero,
918 .extra2 = &one, 915 .extra2 = &one,
@@ -2187,8 +2184,6 @@ static int do_proc_douintvec_conv(unsigned long *lvalp,
2187 if (write) { 2184 if (write) {
2188 if (*lvalp > UINT_MAX) 2185 if (*lvalp > UINT_MAX)
2189 return -EINVAL; 2186 return -EINVAL;
2190 if (*lvalp > UINT_MAX)
2191 return -EINVAL;
2192 *valp = *lvalp; 2187 *valp = *lvalp;
2193 } else { 2188 } else {
2194 unsigned int val = *valp; 2189 unsigned int val = *valp;