]>
git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/blob - tools/testing/selftests/ftrace/test.d/kprobe/multiple_kprobes.tc
bb16cf91f1b53e51856b2a4a5e498002b22ddaaa
2 # SPDX-License-Identifier: GPL-2.0
3 # description: Register/unregister many kprobe events
5 [ -f kprobe_events
] || exit_unsupported
# this is configurable
7 # ftrace fentry skip size depends on the machine architecture.
8 # Currently HAVE_KPROBES_ON_FTRACE defined on x86 and powerpc64le
10 x86_64|i
[3456]86) OFFS
=5;;
15 echo "Setup up to 256 kprobes"
16 grep t
/proc
/kallsyms | cut
-f3 -d" " |
grep -v .
*\\..
* | \
17 head -n 256 |
while read i
; do echo p
${i}+${OFFS} ; done > kprobe_events ||
:
19 echo 1 > events
/kprobes
/enable
20 echo 0 > events
/kprobes
/enable
22 echo "Waiting for unoptimizing & freeing"