From: Michael Jeanson Date: Fri, 11 Nov 2022 15:47:54 +0000 (-0500) Subject: fix: Adjust ranges for RHEL 8.6 kernels X-Git-Tag: v2.12.12~5 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=5d0b3afd73a0dda761eafd5e01a881561baaea4b;p=lttng-modules.git fix: Adjust ranges for RHEL 8.6 kernels Signed-off-by: Michael Jeanson Signed-off-by: Mathieu Desnoyers Change-Id: I0b2c90f3678d0fb4503f61f336a4af185de2b39d --- diff --git a/instrumentation/events/lttng-module/block.h b/instrumentation/events/lttng-module/block.h index 94225b9e..9d57feec 100644 --- a/instrumentation/events/lttng-module/block.h +++ b/instrumentation/events/lttng-module/block.h @@ -335,7 +335,8 @@ LTTNG_TRACEPOINT_EVENT(block_rq_requeue, ) ) #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,11,0) \ - || LTTNG_KERNEL_RANGE(5,10,137, 5,11,0)) + || LTTNG_KERNEL_RANGE(5,10,137, 5,11,0) \ + || LTTNG_RHEL_KERNEL_RANGE(4,18,0,372,0,0, 4,19,0,0,0,0)) /** * block_rq_requeue - place block IO request back on a queue * @rq: block IO operation request @@ -581,7 +582,8 @@ LTTNG_TRACEPOINT_EVENT_CLASS(block_rq, ) ) #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,11,0) \ - || LTTNG_KERNEL_RANGE(5,10,137, 5,11,0)) + || LTTNG_KERNEL_RANGE(5,10,137, 5,11,0) \ + || LTTNG_RHEL_KERNEL_RANGE(4,18,0,372,0,0, 4,19,0,0,0,0)) LTTNG_TRACEPOINT_EVENT_CLASS(block_rq, TP_PROTO(struct request *rq), @@ -717,7 +719,8 @@ LTTNG_TRACEPOINT_EVENT_CLASS_CODE(block_rq, #endif /* #else #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,11,0)) */ #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,11,0) \ - || LTTNG_KERNEL_RANGE(5,10,137, 5,11,0)) + || LTTNG_KERNEL_RANGE(5,10,137, 5,11,0) \ + || LTTNG_RHEL_KERNEL_RANGE(4,18,0,372,0,0, 4,19,0,0,0,0)) /** * block_rq_insert - insert block operation request into queue * @rq: block IO operation request @@ -753,7 +756,8 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE(block_rq, block_rq_insert, #endif #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,11,0) \ - || LTTNG_KERNEL_RANGE(5,10,137, 5,11,0)) + || LTTNG_KERNEL_RANGE(5,10,137, 5,11,0) \ + || LTTNG_RHEL_KERNEL_RANGE(4,18,0,372,0,0, 4,19,0,0,0,0)) /** * block_rq_issue - issue pending block IO request operation to device driver * @rq: block IO operation operation request @@ -1606,7 +1610,8 @@ LTTNG_TRACEPOINT_EVENT(block_rq_remap, ) ) #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,11,0) \ - || LTTNG_KERNEL_RANGE(5,10,137, 5,11,0)) + || LTTNG_KERNEL_RANGE(5,10,137, 5,11,0) \ + || LTTNG_RHEL_KERNEL_RANGE(4,18,0,372,0,0, 4,19,0,0,0,0)) /** * block_rq_remap - map request for a block operation request * @rq: block IO operation request diff --git a/instrumentation/events/lttng-module/kmem.h b/instrumentation/events/lttng-module/kmem.h index c9edee61..5a2bfdb6 100644 --- a/instrumentation/events/lttng-module/kmem.h +++ b/instrumentation/events/lttng-module/kmem.h @@ -87,7 +87,8 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE(kmem_alloc_node, kmem_cache_alloc_node, TP_ARGS(call_site, ptr, bytes_req, bytes_alloc, gfp_flags, node) ) -#if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,12,0)) +#if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,12,0) || \ + LTTNG_RHEL_KERNEL_RANGE(4,18,0,372,0,0, 4,19,0,0,0,0)) LTTNG_TRACEPOINT_EVENT_MAP(kfree, kmem_kfree, diff --git a/wrapper/objtool.h b/wrapper/objtool.h index 67bc1f5f..d4f9cccf 100644 --- a/wrapper/objtool.h +++ b/wrapper/objtool.h @@ -10,7 +10,8 @@ #include -#if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,10,0)) +#if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,10,0) || \ + LTTNG_RHEL_KERNEL_RANGE(4,18,0,372,0,0, 4,19,0,0,0,0)) #include #elif (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(4,6,0)) #include diff --git a/wrapper/sched.h b/wrapper/sched.h index b4772a38..a4cce74d 100644 --- a/wrapper/sched.h +++ b/wrapper/sched.h @@ -11,7 +11,8 @@ #include #include -#if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,14,0)) +#if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,14,0) || \ + LTTNG_RHEL_KERNEL_RANGE(4,18,0,372,0,0, 4,19,0,0,0,0)) #define lttng_get_task_state(task) READ_ONCE((task)->__state) #define lttng_task_is_running(task) task_is_running(task)