This is the mail archive of the
systemtap@sourceware.org
mailing list for the systemtap project.
Calling systemtap function from pure code
- From: Daniel Doron <danielmeirdoron at gmail dot com>
- To: systemtap at sourceware dot org
- Date: Wed, 13 Sep 2017 17:41:09 +0300
- Subject: Calling systemtap function from pure code
- Authentication-results: sourceware.org; auth=none
Hi,
Is it possible to call a stap function from kernel code (guru mode)?
The error I get is:
error: implicit declaration of function ‘log_evnt_stap’
[-Werror=implicit-function-declaration]
e.g.:
=============================
function log_evnt_stap(name){
printf("name %s \n", name )
}
probe begin(0) {
call_me();
}
%{
int log_event(char * str)
{
log_evnt_stap(str);
return 0;
}
%}
function call_me() %{
log_event("hello world");
%}
================================