forked from luck/tmp_suning_uos_patched
kprobes: Use CONFIG_PREEMPTION
CONFIG_PREEMPTION is selected by CONFIG_PREEMPT and by CONFIG_PREEMPT_RT. Both PREEMPT and PREEMPT_RT require the same functionality which today depends on CONFIG_PREEMPT. Switch kprobes conditional over to CONFIG_PREEMPTION. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Paolo Bonzini <pbonzini@redhat.com> Cc: Paul E. McKenney <paulmck@linux.ibm.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Steven Rostedt <rostedt@goodmis.org> Link: http://lkml.kernel.org/r/20190726212124.516286187@linutronix.de Signed-off-by: Ingo Molnar <mingo@kernel.org>
This commit is contained in:
parent
30c937043b
commit
9261660636
|
@ -1906,7 +1906,7 @@ int register_kretprobe(struct kretprobe *rp)
|
||||||
|
|
||||||
/* Pre-allocate memory for max kretprobe instances */
|
/* Pre-allocate memory for max kretprobe instances */
|
||||||
if (rp->maxactive <= 0) {
|
if (rp->maxactive <= 0) {
|
||||||
#ifdef CONFIG_PREEMPT
|
#ifdef CONFIG_PREEMPTION
|
||||||
rp->maxactive = max_t(unsigned int, 10, 2*num_possible_cpus());
|
rp->maxactive = max_t(unsigned int, 10, 2*num_possible_cpus());
|
||||||
#else
|
#else
|
||||||
rp->maxactive = num_possible_cpus();
|
rp->maxactive = num_possible_cpus();
|
||||||
|
|
Loading…
Reference in New Issue
Block a user