diff options
Diffstat (limited to 'kernel/sysctl.c')
-rw-r--r-- | kernel/sysctl.c | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/kernel/sysctl.c b/kernel/sysctl.c index a85047bb5739..03b0598f2369 100644 --- a/kernel/sysctl.c +++ b/kernel/sysctl.c | |||
@@ -68,6 +68,8 @@ extern int min_free_kbytes; | |||
68 | extern int printk_ratelimit_jiffies; | 68 | extern int printk_ratelimit_jiffies; |
69 | extern int printk_ratelimit_burst; | 69 | extern int printk_ratelimit_burst; |
70 | extern int pid_max_min, pid_max_max; | 70 | extern int pid_max_min, pid_max_max; |
71 | extern int sysctl_drop_caches; | ||
72 | extern int percpu_pagelist_fraction; | ||
71 | 73 | ||
72 | #if defined(CONFIG_X86_LOCAL_APIC) && defined(CONFIG_X86) | 74 | #if defined(CONFIG_X86_LOCAL_APIC) && defined(CONFIG_X86) |
73 | int unknown_nmi_panic; | 75 | int unknown_nmi_panic; |
@@ -78,6 +80,7 @@ extern int proc_unknown_nmi_panic(ctl_table *, int, struct file *, | |||
78 | /* this is needed for the proc_dointvec_minmax for [fs_]overflow UID and GID */ | 80 | /* this is needed for the proc_dointvec_minmax for [fs_]overflow UID and GID */ |
79 | static int maxolduid = 65535; | 81 | static int maxolduid = 65535; |
80 | static int minolduid; | 82 | static int minolduid; |
83 | static int min_percpu_pagelist_fract = 8; | ||
81 | 84 | ||
82 | static int ngroups_max = NGROUPS_MAX; | 85 | static int ngroups_max = NGROUPS_MAX; |
83 | 86 | ||
@@ -775,6 +778,15 @@ static ctl_table vm_table[] = { | |||
775 | .strategy = &sysctl_intvec, | 778 | .strategy = &sysctl_intvec, |
776 | }, | 779 | }, |
777 | { | 780 | { |
781 | .ctl_name = VM_DROP_PAGECACHE, | ||
782 | .procname = "drop_caches", | ||
783 | .data = &sysctl_drop_caches, | ||
784 | .maxlen = sizeof(int), | ||
785 | .mode = 0644, | ||
786 | .proc_handler = drop_caches_sysctl_handler, | ||
787 | .strategy = &sysctl_intvec, | ||
788 | }, | ||
789 | { | ||
778 | .ctl_name = VM_MIN_FREE_KBYTES, | 790 | .ctl_name = VM_MIN_FREE_KBYTES, |
779 | .procname = "min_free_kbytes", | 791 | .procname = "min_free_kbytes", |
780 | .data = &min_free_kbytes, | 792 | .data = &min_free_kbytes, |
@@ -784,6 +796,16 @@ static ctl_table vm_table[] = { | |||
784 | .strategy = &sysctl_intvec, | 796 | .strategy = &sysctl_intvec, |
785 | .extra1 = &zero, | 797 | .extra1 = &zero, |
786 | }, | 798 | }, |
799 | { | ||
800 | .ctl_name = VM_PERCPU_PAGELIST_FRACTION, | ||
801 | .procname = "percpu_pagelist_fraction", | ||
802 | .data = &percpu_pagelist_fraction, | ||
803 | .maxlen = sizeof(percpu_pagelist_fraction), | ||
804 | .mode = 0644, | ||
805 | .proc_handler = &percpu_pagelist_fraction_sysctl_handler, | ||
806 | .strategy = &sysctl_intvec, | ||
807 | .extra1 = &min_percpu_pagelist_fract, | ||
808 | }, | ||
787 | #ifdef CONFIG_MMU | 809 | #ifdef CONFIG_MMU |
788 | { | 810 | { |
789 | .ctl_name = VM_MAX_MAP_COUNT, | 811 | .ctl_name = VM_MAX_MAP_COUNT, |