This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Calling systemtap function from pure code


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");
%}
================================


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]