Makes kprobe attribute specific to kernel
[lttng-tools.git] / include / lttng-kernel.h
index 142de0706ef670bdbcd7680961333adcb2da37d5..29731748501aee899240b27b2976f218e26b1bf3 100644 (file)
 
 #include "lttng-share.h"
 
+#define LTTNG_SYM_NAME_LEN  128
+
+enum lttng_kernel_instrumentation {
+       LTTNG_KERNEL_TRACEPOINT    = 0,
+       LTTNG_KERNEL_KPROBE        = 1,
+       LTTNG_KERNEL_FUNCTION      = 2,
+};
+
+/*
+ * LTTng consumer mode
+ */
+enum lttng_kernel_output {
+       LTTNG_KERNEL_SPLICE       = 0,
+       LTTNG_KERNEL_MMAP         = 1,
+};
+
 /*
  * LTTng DebugFS ABI structures.
+ *
+ * This is the kernel ABI copied from lttng-modules tree.
  */
-enum lttng_instrum_type {
-       INSTRUM_TRACEPOINTS,
+
+/* Function tracer */
+struct lttng_kernel_function_attr {
+       char symbol_name[LTTNG_SYM_NAME_LEN];
 };
 
-struct lttng_channel {
-       int overwrite;         /* 1: overwrite, 0: discard */
-       u64 subbuf_size;
-       u64 num_subbuf;
-       unsigned int switch_timer_interval;
-       unsigned int read_timer_interval;
+struct lttng_kernel_event {
+       char name[LTTNG_SYM_NAME_LEN];
+       enum lttng_kernel_instrumentation instrumentation;
+       /* Per instrumentation type configuration */
+       union {
+               struct lttng_kernel_kprobe_attr kprobe;
+               struct lttng_kernel_function_attr ftrace;
+       } u;
 };
 
-struct lttng_event {
-       enum lttng_instrum_type itype;
-       char name[];
+struct lttng_kernel_tracer_version {
+       uint32_t version;
+       uint32_t patchlevel;
+       uint32_t sublevel;
 };
 
 #endif /* _LTTNG_KERNEL_H */
This page took 0.044179 seconds and 4 git commands to generate.