From: Michael Jeanson Date: Tue, 11 May 2021 20:16:18 +0000 (-0400) Subject: Disable clone bitwise enum in default build X-Git-Tag: v2.13.0-rc2~8 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=f0bfef4ee9cd4c250fd9386b786966c2f01b3ae0;p=lttng-modules.git Disable clone bitwise enum in default build Only generate the bitwise enumerations when CONFIG_LTTNG_EXPERIMENTAL_BITWISE_ENUM is enabled, so the default build does not generate traces which lead to warnings when viewed with babeltrace 1.x and babeltrace 2 with default options. Original commit: commit d775625e2ba4825b73b5897e7701ad6e2bdba115 Author: Geneviève Bastien Date: Wed Apr 1 14:31:49 2020 -0400 syscalls: Make clone()'s `flags` field a 2 enum struct. Change-Id: Ia67b5fc93b932b8b76330b4965753a43401c1514 Signed-off-by: Michael Jeanson Signed-off-by: Mathieu Desnoyers --- diff --git a/include/instrumentation/syscalls/headers/syscalls_pointers_override.h b/include/instrumentation/syscalls/headers/syscalls_pointers_override.h index c84efdc9..ff91a654 100644 --- a/include/instrumentation/syscalls/headers/syscalls_pointers_override.h +++ b/include/instrumentation/syscalls/headers/syscalls_pointers_override.h @@ -14,6 +14,8 @@ SC_LTTNG_TRACEPOINT_EVENT(execve, ) ) +#ifdef CONFIG_LTTNG_EXPERIMENTAL_BITWISE_ENUM + /* * Clone()'s `flags` field has two parts: * 1. exit signal: the least significant byte of the `unsigned long` is @@ -145,6 +147,7 @@ lttng_kernel_static_event_field_array( \ ) #endif +#endif /* CONFIG_LTTNG_EXPERIMENTAL_BITWISE_ENUM */ #define OVERRIDE_32_clone #define OVERRIDE_64_clone @@ -156,6 +159,7 @@ SC_LTTNG_TRACEPOINT_EVENT(clone, TP_FIELDS( sc_exit(ctf_integer(long, ret, ret)) sc_in( +#ifdef CONFIG_LTTNG_EXPERIMENTAL_BITWISE_ENUM ctf_custom_field( ctf_custom_type( lttng_kernel_static_type_struct(2, LTTNG_CLONE_FLAGS, lttng_alignof(unsigned long) * CHAR_BIT) @@ -165,6 +169,9 @@ SC_LTTNG_TRACEPOINT_EVENT(clone, ctf_integer_type(unsigned long, clone_flags) ) ) +#else + ctf_integer_hex(unsigned long, flags, clone_flags) +#endif ) sc_in(ctf_integer_hex(unsigned long, newsp, newsp)) sc_in(ctf_integer_hex(void *, parent_tid, parent_tid))