Commit edbaadbe authored by Namhyung Kim's avatar Namhyung Kim Committed by Ingo Molnar

kprobes: Remove redundant address check

Remove call to kernel_text_address() in register_jprobes()
because it is called right after in register_kprobe().
Signed-off-by: default avatarNamhyung Kim <namhyung@gmail.com>
Acked-by: default avatarMasami Hiramatsu <masami.hiramatsu.pt@hitachi.com>
LKML-Reference: <1284512670-2369-2-git-send-email-namhyung@gmail.com>
Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
parent 38a81da2
...@@ -1343,14 +1343,11 @@ int __kprobes register_jprobes(struct jprobe **jps, int num) ...@@ -1343,14 +1343,11 @@ int __kprobes register_jprobes(struct jprobe **jps, int num)
jp = jps[i]; jp = jps[i];
addr = arch_deref_entry_point(jp->entry); addr = arch_deref_entry_point(jp->entry);
if (!kernel_text_address(addr))
ret = -EINVAL;
else {
/* Todo: Verify probepoint is a function entry point */ /* Todo: Verify probepoint is a function entry point */
jp->kp.pre_handler = setjmp_pre_handler; jp->kp.pre_handler = setjmp_pre_handler;
jp->kp.break_handler = longjmp_break_handler; jp->kp.break_handler = longjmp_break_handler;
ret = register_kprobe(&jp->kp); ret = register_kprobe(&jp->kp);
}
if (ret < 0) { if (ret < 0) {
if (i > 0) if (i > 0)
unregister_jprobes(jps, i); unregister_jprobes(jps, i);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment