diff options
Diffstat (limited to 'kernel/sysctl.c')
-rw-r--r-- | kernel/sysctl.c | 55 |
1 files changed, 33 insertions, 22 deletions
diff --git a/kernel/sysctl.c b/kernel/sysctl.c index f73da1c857eb..9acfce0cdfdb 100644 --- a/kernel/sysctl.c +++ b/kernel/sysctl.c | |||
@@ -76,6 +76,10 @@ | |||
76 | #include <scsi/sg.h> | 76 | #include <scsi/sg.h> |
77 | #endif | 77 | #endif |
78 | 78 | ||
79 | #ifdef CONFIG_LOCKUP_DETECTOR | ||
80 | #include <linux/nmi.h> | ||
81 | #endif | ||
82 | |||
79 | 83 | ||
80 | #if defined(CONFIG_SYSCTL) | 84 | #if defined(CONFIG_SYSCTL) |
81 | 85 | ||
@@ -106,7 +110,7 @@ extern int blk_iopoll_enabled; | |||
106 | #endif | 110 | #endif |
107 | 111 | ||
108 | /* Constants used for minimum and maximum */ | 112 | /* Constants used for minimum and maximum */ |
109 | #ifdef CONFIG_DETECT_SOFTLOCKUP | 113 | #ifdef CONFIG_LOCKUP_DETECTOR |
110 | static int sixty = 60; | 114 | static int sixty = 60; |
111 | static int neg_one = -1; | 115 | static int neg_one = -1; |
112 | #endif | 116 | #endif |
@@ -710,7 +714,34 @@ static struct ctl_table kern_table[] = { | |||
710 | .mode = 0444, | 714 | .mode = 0444, |
711 | .proc_handler = proc_dointvec, | 715 | .proc_handler = proc_dointvec, |
712 | }, | 716 | }, |
713 | #if defined(CONFIG_X86_LOCAL_APIC) && defined(CONFIG_X86) | 717 | #if defined(CONFIG_LOCKUP_DETECTOR) |
718 | { | ||
719 | .procname = "watchdog", | ||
720 | .data = &watchdog_enabled, | ||
721 | .maxlen = sizeof (int), | ||
722 | .mode = 0644, | ||
723 | .proc_handler = proc_dowatchdog_enabled, | ||
724 | }, | ||
725 | { | ||
726 | .procname = "watchdog_thresh", | ||
727 | .data = &softlockup_thresh, | ||
728 | .maxlen = sizeof(int), | ||
729 | .mode = 0644, | ||
730 | .proc_handler = proc_dowatchdog_thresh, | ||
731 | .extra1 = &neg_one, | ||
732 | .extra2 = &sixty, | ||
733 | }, | ||
734 | { | ||
735 | .procname = "softlockup_panic", | ||
736 | .data = &softlockup_panic, | ||
737 | .maxlen = sizeof(int), | ||
738 | .mode = 0644, | ||
739 | .proc_handler = proc_dointvec_minmax, | ||
740 | .extra1 = &zero, | ||
741 | .extra2 = &one, | ||
742 | }, | ||
743 | #endif | ||
744 | #if defined(CONFIG_X86_LOCAL_APIC) && defined(CONFIG_X86) && !defined(CONFIG_LOCKUP_DETECTOR) | ||
714 | { | 745 | { |
715 | .procname = "unknown_nmi_panic", | 746 | .procname = "unknown_nmi_panic", |
716 | .data = &unknown_nmi_panic, | 747 | .data = &unknown_nmi_panic, |
@@ -813,26 +844,6 @@ static struct ctl_table kern_table[] = { | |||
813 | .proc_handler = proc_dointvec, | 844 | .proc_handler = proc_dointvec, |
814 | }, | 845 | }, |
815 | #endif | 846 | #endif |
816 | #ifdef CONFIG_DETECT_SOFTLOCKUP | ||
817 | { | ||
818 | .procname = "softlockup_panic", | ||
819 | .data = &softlockup_panic, | ||
820 | .maxlen = sizeof(int), | ||
821 | .mode = 0644, | ||
822 | .proc_handler = proc_dointvec_minmax, | ||
823 | .extra1 = &zero, | ||
824 | .extra2 = &one, | ||
825 | }, | ||
826 | { | ||
827 | .procname = "softlockup_thresh", | ||
828 | .data = &softlockup_thresh, | ||
829 | .maxlen = sizeof(int), | ||
830 | .mode = 0644, | ||
831 | .proc_handler = proc_dosoftlockup_thresh, | ||
832 | .extra1 = &neg_one, | ||
833 | .extra2 = &sixty, | ||
834 | }, | ||
835 | #endif | ||
836 | #ifdef CONFIG_DETECT_HUNG_TASK | 847 | #ifdef CONFIG_DETECT_HUNG_TASK |
837 | { | 848 | { |
838 | .procname = "hung_task_panic", | 849 | .procname = "hung_task_panic", |