Skip to content

Instantly share code, notes, and snippets.

@agentzh

agentzh/a.log Secret

Created June 19, 2020 22:05
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save agentzh/7c86860b7ef02865cd86a9357e05fa2c to your computer and use it in GitHub Desktop.
Save agentzh/7c86860b7ef02865cd86a9357e05fa2c to your computer and use it in GitHub Desktop.
$ stap -e 'probe oneshot { println("Hello World") }'
In file included from /opt/stap/share/systemtap/runtime/linux/runtime.h:31,
from /opt/stap/share/systemtap/runtime/runtime.h:26,
from /tmp/stap3J1nYx/stap_0521ff2c831c444a6d83982f49391af0_1250_src.c:21:
./include/linux/vermagic.h:6:2: error: #error "This header can be included from kernel/module.c or *.mod.c only"
6 | #error "This header can be included from kernel/module.c or *.mod.c only"
| ^~~~~
In file included from /opt/stap/share/systemtap/runtime/linux/runtime.h:230,
from /opt/stap/share/systemtap/runtime/runtime.h:26,
from /tmp/stap3J1nYx/stap_0521ff2c831c444a6d83982f49391af0_1250_src.c:21:
/opt/stap/share/systemtap/runtime/linux/access_process_vm.h: In function ‘__access_process_vm_’:
/opt/stap/share/systemtap/runtime/linux/access_process_vm.h:32:19: error: ‘struct mm_struct’ has no member named ‘mmap_sem’; did you mean ‘mmap_base’?
32 | down_read (&mm->mmap_sem);
| ^~~~~~~~
| mmap_base
/opt/stap/share/systemtap/runtime/linux/access_process_vm.h:87:17: error: ‘struct mm_struct’ has no member named ‘mmap_sem’; did you mean ‘mmap_base’?
87 | up_read (&mm->mmap_sem);
| ^~~~~~~~
| mmap_base
In file included from /opt/stap/share/systemtap/runtime/linux/task_finder.c:17,
from /opt/stap/share/systemtap/runtime/linux/runtime.h:243,
from /opt/stap/share/systemtap/runtime/runtime.h:26,
from /tmp/stap3J1nYx/stap_0521ff2c831c444a6d83982f49391af0_1250_src.c:21:
/opt/stap/share/systemtap/runtime/linux/task_finder2.c: In function ‘__stp_call_mmap_callbacks_with_addr’:
/opt/stap/share/systemtap/runtime/linux/task_finder2.c:740:31: error: ‘struct mm_struct’ has no member named ‘mmap_sem’; did you mean ‘mmap_base’?
740 | if (! down_read_trylock(&mm->mmap_sem))
| ^~~~~~~~
| mmap_base
/opt/stap/share/systemtap/runtime/linux/task_finder2.c:758:17: error: ‘struct mm_struct’ has no member named ‘mmap_sem’; did you mean ‘mmap_base’?
758 | up_read(&mm->mmap_sem);
| ^~~~~~~~
| mmap_base
/opt/stap/share/systemtap/runtime/linux/task_finder2.c:785:15: error: ‘struct mm_struct’ has no member named ‘mmap_sem’; did you mean ‘mmap_base’?
785 | up_read(&mm->mmap_sem);
| ^~~~~~~~
| mmap_base
/opt/stap/share/systemtap/runtime/linux/task_finder2.c: In function ‘__stp_call_mmap_callbacks_for_task’:
/opt/stap/share/systemtap/runtime/linux/task_finder2.c:1230:31: error: ‘struct mm_struct’ has no member named ‘mmap_sem’; did you mean ‘mmap_base’?
1230 | if (! down_read_trylock(&mm->mmap_sem)) {
| ^~~~~~~~
| mmap_base
/opt/stap/share/systemtap/runtime/linux/task_finder2.c:1284:15: error: ‘struct mm_struct’ has no member named ‘mmap_sem’; did you mean ‘mmap_base’?
1284 | up_read(&mm->mmap_sem);
| ^~~~~~~~
| mmap_base
make[1]: *** [scripts/Makefile.build:280: /tmp/stap3J1nYx/stap_0521ff2c831c444a6d83982f49391af0_1250_src.o] Error 1
make: *** [Makefile:1774: /tmp/stap3J1nYx] Error 2
WARNING: kbuild exited with status: 2
Pass 4: compilation failed. [man error::pass4]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment