From: Michael Jeanson Date: Tue, 18 May 2021 15:16:34 +0000 (-0400) Subject: fix: adjust ranges for RHEL 8.4 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=fce87a6ebf4a69ab032f6d305d947d3973a3932a;p=lttng-modules.git fix: adjust ranges for RHEL 8.4 Change-Id: I9ac44467cca4850fb4051252937542d5a054ccc4 Signed-off-by: Michael Jeanson Signed-off-by: Mathieu Desnoyers --- diff --git a/include/instrumentation/events/block.h b/include/instrumentation/events/block.h index 7ec7d619..3895c9d4 100644 --- a/include/instrumentation/events/block.h +++ b/include/instrumentation/events/block.h @@ -734,7 +734,9 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE(block_rq, block_rq_merge, ) #endif -#if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,8,0)) +#if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,8,0) || \ + LTTNG_RHEL_KERNEL_RANGE(4,18,0,305,0,0, 4,19,0,0,0,0)) + /** * block_bio_complete - completed all work on the block operation * @q: queue holding the block operation diff --git a/include/instrumentation/events/lttng-statedump.h b/include/instrumentation/events/lttng-statedump.h index cc835e29..345beee5 100644 --- a/include/instrumentation/events/lttng-statedump.h +++ b/include/instrumentation/events/lttng-statedump.h @@ -17,7 +17,8 @@ #include #include #include -#if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,6,0)) +#if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,6,0) || \ + LTTNG_RHEL_KERNEL_RANGE(4,18,0,305,0,0, 4,19,0,0,0,0)) #include #endif @@ -182,7 +183,8 @@ LTTNG_TRACEPOINT_EVENT(lttng_statedump_process_uts_ns, ) ) -#if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,6,0)) +#if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,6,0) || \ + LTTNG_RHEL_KERNEL_RANGE(4,18,0,305,0,0, 4,19,0,0,0,0)) LTTNG_TRACEPOINT_EVENT(lttng_statedump_process_time_ns, TP_PROTO(struct lttng_kernel_session *session, struct task_struct *p, diff --git a/include/instrumentation/events/mm_vmscan.h b/include/instrumentation/events/mm_vmscan.h index 1e2ef3fc..4ba907b2 100644 --- a/include/instrumentation/events/mm_vmscan.h +++ b/include/instrumentation/events/mm_vmscan.h @@ -26,7 +26,8 @@ typedef int isolate_mode_t; #endif -#if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,2,0)) +#if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,2,0) || \ + LTTNG_RHEL_KERNEL_RANGE(4,18,0,305,0,0, 4,19,0,0,0,0)) #include @@ -123,7 +124,8 @@ LTTNG_TRACEPOINT_EVENT(mm_vmscan_wakeup_kswapd, ) #endif -#if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,2,0)) +#if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,2,0) || \ + LTTNG_RHEL_KERNEL_RANGE(4,18,0,305,0,0, 4,19,0,0,0,0)) LTTNG_TRACEPOINT_EVENT_CLASS(mm_vmscan_direct_reclaim_begin_template, @@ -621,7 +623,8 @@ LTTNG_TRACEPOINT_EVENT(mm_vmscan_writepage, ) #endif -#if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,2,0)) +#if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,2,0) || \ + LTTNG_RHEL_KERNEL_RANGE(4,18,0,305,0,0, 4,19,0,0,0,0)) LTTNG_TRACEPOINT_EVENT(mm_vmscan_lru_shrink_inactive, TP_PROTO(int nid, diff --git a/include/instrumentation/events/writeback.h b/include/instrumentation/events/writeback.h index b5fbda9e..c4510b44 100644 --- a/include/instrumentation/events/writeback.h +++ b/include/instrumentation/events/writeback.h @@ -439,7 +439,8 @@ LTTNG_TRACEPOINT_EVENT(writeback_queue_io, ) #endif -#if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,8,0)) +#if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,8,0) || \ + LTTNG_RHEL_KERNEL_RANGE(4,18,0,305,0,0, 4,19,0,0,0,0)) LTTNG_TRACEPOINT_EVENT_MAP(global_dirty_state, writeback_global_dirty_state, diff --git a/include/lttng/events-internal.h b/include/lttng/events-internal.h index 3923232b..cd560de8 100644 --- a/include/lttng/events-internal.h +++ b/include/lttng/events-internal.h @@ -714,7 +714,8 @@ int lttng_add_uts_ns_to_ctx(struct lttng_kernel_ctx **ctx) #endif #if defined(CONFIG_TIME_NS) && \ - (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,6,0)) + (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,6,0) || \ + LTTNG_RHEL_KERNEL_RANGE(4,18,0,305,0,0, 4,19,0,0,0,0)) int lttng_add_time_ns_to_ctx(struct lttng_kernel_ctx **ctx); #else static inline diff --git a/src/lttng-statedump-impl.c b/src/lttng-statedump-impl.c index a9a757bc..164345ca 100644 --- a/src/lttng-statedump-impl.c +++ b/src/lttng-statedump-impl.c @@ -617,7 +617,8 @@ void lttng_statedump_process_ns(struct lttng_kernel_session *session, #endif trace_lttng_statedump_process_net_ns(session, p, proxy->net_ns); trace_lttng_statedump_process_uts_ns(session, p, proxy->uts_ns); -#if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,6,0)) +#if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,6,0) || \ + LTTNG_RHEL_KERNEL_RANGE(4,18,0,305,0,0, 4,19,0,0,0,0)) trace_lttng_statedump_process_time_ns(session, p, proxy->time_ns); #endif }