lkml.org 
[lkml]   [2006]   [Mar]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRE: [PATCH] provide hrtimer exports for module use [Was:Exportsfor hrtimer APIs]
Date
From
Thomas Gleixner wrote:
> I have no clue where the block of code written by the user is executed
> and why it needs exports. When a user writes code he can use the
> existing userpsace interfaces, so why does the module need that
> exports ?

Sorry - by user I mean a SystemTap user, who must be a priviledged user
to run SystemTap and load a kernel module in the first place. When a
script is executed, the following happens:

1. The script with the user's probes is parsed by SystemTap.
2. SystemTap generates C code for a kernel module that implements the
probes.
3. The module is compiled and loaded into the kernel.
4. On loading, the probes register with the appropriate kernel APIs.
For function probes, this means using the kprobes interface. For
asynchronous timer probes, the module must call timer APIs - e.g.
hrtimers.
5. As the events occur, the probe bodies are executed.
6. Finally the module terminates, unregisters all probes, and is
unloaded from the kernel.

In order to call hrtimer_init and such in step 4, those functions need
to be exported.


Josh
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2006-03-15 00:34    [W:0.023 / U:0.228 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site