X-Git-Url: http://git.lttng.org/?a=blobdiff_plain;f=lttng-abi.h;h=dc230d86dab4d75b60eccc29f39f8fbd0a6c0c6c;hb=4798baec2eaada44be415af23c844d810b284c42;hp=b5410d49b19cf7adee3e75ab12a31c59ce66f0c0;hpb=f8695253467b480087663426f4b97c02c443f08c;p=lttng-modules.git diff --git a/lttng-abi.h b/lttng-abi.h index b5410d49..dc230d86 100644 --- a/lttng-abi.h +++ b/lttng-abi.h @@ -4,11 +4,23 @@ /* * lttng-abi.h * - * Copyright 2010 (c) - Mathieu Desnoyers - * * LTTng ABI header * - * Dual LGPL v2.1/GPL v2 license. + * Copyright (C) 2010-2012 Mathieu Desnoyers + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; only + * version 2.1 of the License. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ #include @@ -35,6 +47,7 @@ enum lttng_kernel_output { /* * LTTng DebugFS ABI structures. */ +#define LTTNG_KERNEL_CHANNEL_PADDING LTTNG_KERNEL_SYM_NAME_LEN + 32 struct lttng_kernel_channel { int overwrite; /* 1: overwrite, 0: discard */ uint64_t subbuf_size; /* in bytes */ @@ -42,6 +55,7 @@ struct lttng_kernel_channel { unsigned int switch_timer_interval; /* usecs */ unsigned int read_timer_interval; /* usecs */ enum lttng_kernel_output output; /* splice, mmap */ + char padding[LTTNG_KERNEL_CHANNEL_PADDING]; }; struct lttng_kernel_kretprobe { @@ -68,21 +82,26 @@ struct lttng_kernel_function_tracer { /* * For syscall tracing, name = '\0' means "enable all". */ +#define LTTNG_KERNEL_EVENT_PADDING1 16 +#define LTTNG_KERNEL_EVENT_PADDING2 LTTNG_KERNEL_SYM_NAME_LEN + 32 struct lttng_kernel_event { char name[LTTNG_KERNEL_SYM_NAME_LEN]; /* event name */ enum lttng_kernel_instrumentation instrumentation; + char padding[LTTNG_KERNEL_EVENT_PADDING1]; + /* Per instrumentation type configuration */ union { struct lttng_kernel_kretprobe kretprobe; struct lttng_kernel_kprobe kprobe; struct lttng_kernel_function_tracer ftrace; + char padding[LTTNG_KERNEL_EVENT_PADDING2]; } u; }; struct lttng_kernel_tracer_version { - uint32_t version; + uint32_t major; + uint32_t minor; uint32_t patchlevel; - uint32_t sublevel; }; enum lttng_kernel_calibrate_type { @@ -112,10 +131,15 @@ struct lttng_kernel_perf_counter_ctx { char name[LTTNG_KERNEL_SYM_NAME_LEN]; }; +#define LTTNG_KERNEL_CONTEXT_PADDING1 16 +#define LTTNG_KERNEL_CONTEXT_PADDING2 LTTNG_KERNEL_SYM_NAME_LEN + 32 struct lttng_kernel_context { enum lttng_kernel_context_type ctx; + char padding[LTTNG_KERNEL_CONTEXT_PADDING1]; + union { struct lttng_kernel_perf_counter_ctx perf_counter; + char padding[LTTNG_KERNEL_CONTEXT_PADDING2]; } u; };