summaryrefslogtreecommitdiffstats
path: root/meta/recipes-kernel/lttng/lttng-modules/0019-fix-random-tracepoints-removed-in-stable-kernels.patch
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-kernel/lttng/lttng-modules/0019-fix-random-tracepoints-removed-in-stable-kernels.patch')
-rw-r--r--meta/recipes-kernel/lttng/lttng-modules/0019-fix-random-tracepoints-removed-in-stable-kernels.patch51
1 files changed, 51 insertions, 0 deletions
diff --git a/meta/recipes-kernel/lttng/lttng-modules/0019-fix-random-tracepoints-removed-in-stable-kernels.patch b/meta/recipes-kernel/lttng/lttng-modules/0019-fix-random-tracepoints-removed-in-stable-kernels.patch
new file mode 100644
index 0000000000..73ba4d06bc
--- /dev/null
+++ b/meta/recipes-kernel/lttng/lttng-modules/0019-fix-random-tracepoints-removed-in-stable-kernels.patch
@@ -0,0 +1,51 @@
1From 2c98e0cd03eba0aa935796bc7413c51b5e4b055c Mon Sep 17 00:00:00 2001
2From: Michael Jeanson <mjeanson@efficios.com>
3Date: Tue, 31 May 2022 15:24:48 -0400
4Subject: [PATCH 19/19] fix: 'random' tracepoints removed in stable kernels
5
6The upstream commit 14c174633f349cb41ea90c2c0aaddac157012f74 removing
7the 'random' tracepoints is being backported to multiple stable kernel
8branches, I don't see how that qualifies as a fix but here we are.
9
10Use the presence of 'include/trace/events/random.h' in the kernel source
11tree instead of the rather tortuous version check to determine if we
12need to build 'lttng-probe-random.ko'.
13
14Upstream-Status: Backport [ed1149ef88fb62c365ac66cf62c58ac6abd8d7e8]
15Change-Id: I8f5f2f4c9e09c61127c49c7949b22dd3fab0460d
16Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
17Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
18---
19 probes/Kbuild | 16 ++++------------
20 1 file changed, 4 insertions(+), 12 deletions(-)
21
22diff --git a/probes/Kbuild b/probes/Kbuild
23index 87f2d681..f09d6b65 100644
24--- a/probes/Kbuild
25+++ b/probes/Kbuild
26@@ -216,18 +216,10 @@ ifneq ($(CONFIG_FRAME_WARN),0)
27 endif
28
29 # Introduced in v3.6, remove in v5.18
30-obj-$(CONFIG_LTTNG) += $(shell \
31- if [ \( ! \( $(VERSION) -ge 6 \
32- -o \( $(VERSION) -eq 5 -a $(PATCHLEVEL) -ge 18 \) \
33- -o \( $(VERSION) -eq 5 -a $(PATCHLEVEL) -eq 15 -a $(SUBLEVEL) -ge 44 \) \
34- -o \( $(VERSION) -eq 5 -a $(PATCHLEVEL) -eq 10 -a $(SUBLEVEL) -ge 119\) \) \) \
35- -a \
36- $(VERSION) -ge 4 \
37- -o \( $(VERSION) -eq 3 -a $(PATCHLEVEL) -ge 6 \) \
38- -o \( $(VERSION) -eq 3 -a $(PATCHLEVEL) -eq 5 -a $(SUBLEVEL) -ge 2 \) \
39- -o \( $(VERSION) -eq 3 -a $(PATCHLEVEL) -eq 4 -a $(SUBLEVEL) -ge 9 \) \
40- -o \( $(VERSION) -eq 3 -a $(PATCHLEVEL) -eq 0 -a $(SUBLEVEL) -ge 41 \) ] ; then \
41- echo "lttng-probe-random.o" ; fi;)
42+random_dep = $(srctree)/include/trace/events/random.h
43+ifneq ($(wildcard $(random_dep)),)
44+ obj-$(CONFIG_LTTNG) += lttng-probe-random.o
45+endif
46
47 obj-$(CONFIG_LTTNG) += $(shell \
48 if [ $(VERSION) -ge 4 \
49--
502.35.1
51