History

ptrace: kill trivial tracehooks

At this point, tracehooks aren't useful to mainline kernel and mostly just add an extra layer of obfuscation. Although they have comments, without actual in-kernel users, it is difficult to tell what are their assumptions and they're actually trying to achieve. To mainline kernel, they just aren't worth keeping around. This patch kills the following trivial tracehooks. * Ones testing whether task is ptraced. Replace with ->ptrace test. tracehook_expect_breakpoints() tracehook_consider_ignored_signal() tracehook_consider_fatal_signal() * ptrace_event() wrappers. Call directly. tracehook_report_exec() tracehook_report_exit() tracehook_report_vfork_done() * ptrace_release_task() wrapper. Call directly. tracehook_finish_release_task() * noop tracehook_prepare_release_task() tracehook_report_death() This doesn't introduce any behavior change.

Tejun Heo committed 15 years ago

Commit a288eec1 parent f3c04b97 files · +11 −171Browse files

Showing the changes to kernel/fork.c (1 of 7 files). Show all

Unified · Split

kernel/fork.c+1−1
@@ -1527,7 +1527,7 @@ long do_fork(unsigned long clone_flags, · 1526 unmodified lines
15271527 freezer_do_not_count();
15281528 wait_for_completion(&vfork);
15291529 freezer_count();
1530− tracehook_report_vfork_done(p, nr);
1530+ ptrace_event(PTRACE_EVENT_VFORK_DONE, nr);
15311531 }
15321532 } else {
15331533 nr = PTR_ERR(p);