File tree Expand file tree Collapse file tree 1 file changed +31
-0
lines changed
tools/testing/selftests/ftrace/test.d/ftrace Expand file tree Collapse file tree 1 file changed +31
-0
lines changed Original file line number Diff line number Diff line change
1
+ #! /bin/sh
2
+ # SPDX-License-Identifier: GPL-2.0
3
+ # description: ftrace - function profiler with function graph tracing
4
+ # requires: function_profile_enabled set_ftrace_filter function_graph:tracer
5
+
6
+ # The function graph tracer can now be run along side of the function
7
+ # profiler. But there was a bug that caused the combination of the two
8
+ # to crash. It also required the function graph tracer to be started
9
+ # first.
10
+ #
11
+ # This test triggers that bug
12
+ #
13
+ # We need both function_graph and profiling to run this test
14
+
15
+ fail () { # mesg
16
+ echo $1
17
+ exit_fail
18
+ }
19
+
20
+ echo " Enabling function graph tracer:"
21
+ echo function_graph > current_tracer
22
+ echo " enable profiler"
23
+
24
+ # Older kernels do not allow function_profile to be enabled with
25
+ # function graph tracer. If the below fails, mark it as unsupported
26
+ echo 1 > function_profile_enabled || exit_unsupported
27
+
28
+ # Let it run for a bit to make sure nothing explodes
29
+ sleep 1
30
+
31
+ exit 0
You can’t perform that action at this time.
0 commit comments