diff options
author | Peter Zijlstra <a.p.zijlstra@chello.nl> | 2009-05-25 11:39:05 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2009-05-25 15:41:12 -0400 |
commit | a78ac3258782f3e64cb40beb5990808e1febcc0c (patch) | |
tree | 692462a974e4c26bdb7fa7fae727a6b326a0eeee /kernel/sysctl.c | |
parent | 48e22d56ecdeddd1ffb42a02fccba5c6ef42b133 (diff) |
perf_counter: Generic per counter interrupt throttle
Introduce a generic per counter interrupt throttle.
This uses the perf_counter_overflow() quick disable to throttle a specific
counter when its going too fast when a pmu->unthrottle() method is provided
which can undo the quick disable.
Power needs to implement both the quick disable and the unthrottle method.
Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: John Kacur <jkacur@redhat.com>
LKML-Reference: <20090525153931.703093461@chello.nl>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'kernel/sysctl.c')
-rw-r--r-- | kernel/sysctl.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/kernel/sysctl.c b/kernel/sysctl.c index 3cb1849f5989..0c4bf863afa3 100644 --- a/kernel/sysctl.c +++ b/kernel/sysctl.c | |||
@@ -930,6 +930,14 @@ static struct ctl_table kern_table[] = { | |||
930 | .mode = 0644, | 930 | .mode = 0644, |
931 | .proc_handler = &proc_dointvec, | 931 | .proc_handler = &proc_dointvec, |
932 | }, | 932 | }, |
933 | { | ||
934 | .ctl_name = CTL_UNNUMBERED, | ||
935 | .procname = "perf_counter_int_limit", | ||
936 | .data = &sysctl_perf_counter_limit, | ||
937 | .maxlen = sizeof(sysctl_perf_counter_limit), | ||
938 | .mode = 0644, | ||
939 | .proc_handler = &proc_dointvec, | ||
940 | }, | ||
933 | #endif | 941 | #endif |
934 | /* | 942 | /* |
935 | * NOTE: do not add new entries to this table unless you have read | 943 | * NOTE: do not add new entries to this table unless you have read |