selftests/ftrace: Choose target function for filter test from samples

Since the expects the 'exit_mmap()' directly
calls 'kmem_cache_free()', this is vulnerable to code modifications.

Choose the target function for the filter test from the sample
event data so that it can keep test running correctly even if the caller
function name will be changed.


Reported-by: Linux Kernel Functional Testing <>
Fixes: 7f09d639b8c4 ("tracing/selftests: Add test for event filtering on function name")
Signed-off-by: Masami Hiramatsu (Google) <>
Acked-by: Steven Rostedt (Google) <>
1 file changed