From d411a17d7b702036dfbcae58dd4db05f2ba7b697 Mon Sep 17 00:00:00 2001 From: Kienan Stewart Date: Fri, 24 Jan 2025 20:06:13 +0000 Subject: [PATCH] Fix: block request field `rq_disk` removed in SLE15 SP5 See upstream SUSE commit: commit 7bee263be47b123a65778a2072a55d8a6575a9d1 Author: Hannes Reinecke Date: Tue Nov 22 10:27:33 2022 +0100 block: remove the ->rq_disk field in struct request (jsc#PED-1183). suse-commit: 0dce100255e42207b5535eafd10612bf96a4014e Change-Id: Ibb2fb5ae2e40fb012e8545574554bb72ba17d5e6 Signed-off-by: Kienan Stewart Signed-off-by: Mathieu Desnoyers --- include/instrumentation/events/block.h | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/include/instrumentation/events/block.h b/include/instrumentation/events/block.h index 121fb7c6..d60105c5 100644 --- a/include/instrumentation/events/block.h +++ b/include/instrumentation/events/block.h @@ -346,7 +346,8 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE(block_rq_with_error, block_rq_abort, #endif #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,17,0) \ - || LTTNG_RHEL_KERNEL_RANGE(5,14,0,162,0,0, 5,15,0,0,0,0)) + || LTTNG_RHEL_KERNEL_RANGE(5,14,0,162,0,0, 5,15,0,0,0,0) \ + || LTTNG_SLE_VERSION_CODE >= LTTNG_SLE_VERSION(150500, 0, 0)) /** * block_rq_requeue - place block IO request back on a queue * @rq: block IO operation request @@ -372,7 +373,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_RHEL_KERNEL_RANGE(4,18,0,372,0,0, 4,19,0,0,0,0)) + || LTTNG_RHEL_KERNEL_RANGE(4,18,0,372,0,0, 4,19,0,0,0,0) \ + || LTTNG_SLE_VERSION_CODE >= LTTNG_SLE_VERSION(150500, 0, 0)) /** * block_rq_requeue - place block IO request back on a queue * @rq: block IO operation request @@ -443,7 +445,8 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE(block_rq_with_error, block_rq_requeue, * additional work required to complete the request. */ #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,17,0) \ - || LTTNG_RHEL_KERNEL_RANGE(5,14,0,162,0,0, 5,15,0,0,0,0)) + || LTTNG_RHEL_KERNEL_RANGE(5,14,0,162,0,0, 5,15,0,0,0,0) \ + || LTTNG_SLE_VERSION_CODE >= LTTNG_SLE_VERSION(150500, 0, 0)) LTTNG_TRACEPOINT_EVENT(block_rq_complete, TP_PROTO(struct request *rq, blk_status_t error, unsigned int nr_bytes), @@ -601,7 +604,8 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE(block_rq_with_error, block_rq_complete, #endif /* #else #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(3,15,0)) */ #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,17,0) \ - || LTTNG_RHEL_KERNEL_RANGE(5,14,0,162,0,0, 5,15,0,0,0,0)) + || LTTNG_RHEL_KERNEL_RANGE(5,14,0,162,0,0, 5,15,0,0,0,0) \ + || LTTNG_SLE_VERSION_CODE >= LTTNG_SLE_VERSION(150500, 0, 0)) LTTNG_TRACEPOINT_EVENT_CLASS(block_rq, TP_PROTO(struct request *rq), @@ -1622,7 +1626,8 @@ LTTNG_TRACEPOINT_EVENT(block_bio_remap, #endif #if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,17,0) \ - || LTTNG_RHEL_KERNEL_RANGE(5,14,0,162,0,0, 5,15,0,0,0,0)) + || LTTNG_RHEL_KERNEL_RANGE(5,14,0,162,0,0, 5,15,0,0,0,0) \ + || LTTNG_SLE_VERSION_CODE >= LTTNG_SLE_VERSION(150500, 0, 0)) /** * block_rq_remap - map request for a block operation request * @rq: block IO operation request -- 2.39.5