scripts/kprobes_test/gen_code_all.sh
raw| 1 | #! /bin/sh |
| 2 | |
| 3 | set -e |
| 4 | |
| 5 | echo "Generating list of all kernel functions from /proc/kallsyms" |
| 6 | grep ' [tT] ' /proc/kallsyms | fgrep -v '[' | awk '{print $3}' > probes.current |
| 7 | echo "Found `wc -l < probes.current` of them: see probes.current" |
| 8 | |
| 9 | echo "Compiling module" |
| 10 | python gen_code.py |
| 11 | |
| 12 | ls -al kprobe_module.ko |
| 13 | echo "Run insmod kprobe_module.ko, if you dare." |