1 LTTng system call tracing
3 1) lttng-syscall-extractor
5 You need to build a kernel with CONFIG_FTRACE_SYSCALLS=y and
6 CONFIG_KALLSYMS_ALL=y for extraction. Apply the linker patch to get your
7 kernel to keep the system call metadata after boot. Then build and load
8 the LTTng syscall extractor module. The module will fail to load (this
9 is expected). See the dmesg output for system call metadata.
11 2) Generate system call TRACE_EVENT().
13 Take the dmesg metadata and feed it to lttng-syscalls-generate-headers.sh
14 (do not include the ending SUCCESS line), e.g., from the
15 instrumentation/syscalls directory. See the script header for usage example.
16 It should be run for both the integers and pointers types.
18 After these are created, we just need to follow the new system call additions,
19 no need to regenerate the whole thing, since system calls are only appended to.
23 You need to provide override headers (even if they don't contain
24 overrides) for each architecture. Those are meant to contain manual
25 overrides for specific system calls for cases where the script do not
26 generate the correct typing for specific system calls.
28 4) Integrating the new architecture, updating architecture header
30 Edit instrumentation/syscalls/headers/syscalls_integers.h and
31 syscalls_pointers.h. Add the new architecture
32 (e.g. CONFIG_X86_64) to the newly-generated headers
33 (e.g. changing the current x86-64-syscalls-3.10.0-rc7_<CLASS>.h into
34 x86-64-syscalls-3.13.7_<CLASS>.h), then rebuild lttng-modules.