From 25a478153dec14e9b29e0db33ac95b5236f39402 Mon Sep 17 00:00:00 2001 From: Kris Van Hees Date: Sun, 9 Sep 2012 17:18:42 -0400 Subject: [PATCH] Change the DTrace startup handling (at boot time) for SDT. The DTrace OS level handling was initialized at DTrace module load, which caused major indigestion on the side of the scheduler when SDT probe points at crucial locations in the scheduler were being patched by one CPU while another was trying to get some real work done. Even a nice stop_machine() based approach turned out not to be possible, because that *cough* depends on the scheduler also. Instead, the DTrace OS support is initialized from the Linux boot sequence, before SMP is enabled, which removes the complications altogether (and it is a lot cleaner and faster). We also call CPU-specific initialization for DTrace during the boot sequence, albeit *after* the CPUs have been identified for SMP, to ensure that we get accurate information. Renamed sdt_register.c to be dtrace_sdt.c (for consistency). And implemented a better patching of SDT probe points. Added a 'nosdt' kernel command line option to allow system wide diabling of SDT probe points (at the kernel level). This can be used when the patching of SDT probe points somehow causes a problem. Signed-off-by: Kris Van Hees --- dtrace/dtrace_dev.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/dtrace/dtrace_dev.c b/dtrace/dtrace_dev.c index 35abbc81556a..e2293bbb9e74 100644 --- a/dtrace/dtrace_dev.c +++ b/dtrace/dtrace_dev.c @@ -1213,7 +1213,6 @@ int dtrace_dev_init(void) return rc; } - dtrace_os_init(); dtrace_ctf_forceload(); dtrace_modload = dtrace_module_loaded; @@ -1331,6 +1330,4 @@ void dtrace_dev_exit(void) misc_deregister(&dtrace_dev); dtrace_probe_exit(); - - dtrace_os_exit(); } -- 2.50.1