[lttng-dev] [PATCH lttng-tools] Fix: test case can not rely on sched_process_free, use _fork instead

Francis Deslauriers francis.deslauriers at efficios.com
Tue Nov 8 16:05:25 UTC 2016

sched_process_free may not be called during the tracing session if there
is very little activity on the machine the test is run on. We change
this validate to sched_process_fork since we are sure there will be
atleast one generated by the final lttng stop.

Signed-off-by: Francis Deslauriers <francis.deslauriers at efficios.com>
 tests/regression/kernel/test_event_basic | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/tests/regression/kernel/test_event_basic b/tests/regression/kernel/test_event_basic
index aeca02b..584bfc8 100755
--- a/tests/regression/kernel/test_event_basic
+++ b/tests/regression/kernel/test_event_basic
@@ -32,14 +32,14 @@ function test_event_basic()
 	lttng_enable_kernel_event $SESSION_NAME "sched_switch"
 	lttng_enable_kernel_event $SESSION_NAME "sched_process_exit"
-	lttng_enable_kernel_event $SESSION_NAME "sched_process_free"
+	lttng_enable_kernel_event $SESSION_NAME "sched_process_fork"
 	validate_trace "sched_switch" $TRACE_PATH
 	validate_trace "sched_process_exit" $TRACE_PATH
-	validate_trace "sched_process_free" $TRACE_PATH
+	validate_trace "sched_process_fork" $TRACE_PATH
 	destroy_lttng_session_ok $SESSION_NAME

More information about the lttng-dev mailing list