Commit 131c60c3 authored by Masami Hiramatsu's avatar Masami Hiramatsu Committed by Steven Rostedt

selftests: ftrace: Check whether snapshot trigger is supported correctly

If "snapshot" special file doesn't exist, that kernel does
not support snapshot and snapshot trigger too. In that case
snapshot trigger test results to unsupported instead of fail.

Link: http://lkml.kernel.org/r/147928401215.22982.10411665829041109794.stgit@devboxSigned-off-by: default avatarMasami Hiramatsu <mhiramat@kernel.org>
Signed-off-by: default avatarSteven Rostedt <rostedt@goodmis.org>
parent 7786bcca
...@@ -23,6 +23,11 @@ if [ ! -f events/sched/sched_process_fork/trigger ]; then ...@@ -23,6 +23,11 @@ if [ ! -f events/sched/sched_process_fork/trigger ]; then
exit_unsupported exit_unsupported
fi fi
if [ ! -f snapshot ]; then
echo "snapshot is not supported"
exit_unsupported
fi
reset_tracer reset_tracer
do_reset do_reset
......
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