diff options
Diffstat (limited to 'meta/recipes-kernel')
-rw-r--r-- | meta/recipes-kernel/lttng/lttng-modules/0001-lttng-modules-backport-writeback.h-changes-from-2.12.patch | 128 | ||||
-rw-r--r-- | meta/recipes-kernel/lttng/lttng-modules_2.11.2.bb | 7 |
2 files changed, 132 insertions, 3 deletions
diff --git a/meta/recipes-kernel/lttng/lttng-modules/0001-lttng-modules-backport-writeback.h-changes-from-2.12.patch b/meta/recipes-kernel/lttng/lttng-modules/0001-lttng-modules-backport-writeback.h-changes-from-2.12.patch new file mode 100644 index 0000000000..25b0a57bc6 --- /dev/null +++ b/meta/recipes-kernel/lttng/lttng-modules/0001-lttng-modules-backport-writeback.h-changes-from-2.12.patch | |||
@@ -0,0 +1,128 @@ | |||
1 | From 66d0869cf54ed79a33345f537dce2f7840e279f0 Mon Sep 17 00:00:00 2001 | ||
2 | From: Bruce Ashfield <bruce.ashfield@gmail.com> | ||
3 | Date: Tue, 29 Sep 2020 10:28:20 -0400 | ||
4 | Subject: [PATCH] lttng-modules: backport writeback.h changes from 2.12.x to | ||
5 | fix kernel 5.4.62+ | ||
6 | |||
7 | Backporting the kernel version changes for writeback.h to fix | ||
8 | compilation against kernel stable versions 5.4.62+ | ||
9 | |||
10 | This is a combination of upstream commits: | ||
11 | |||
12 | 87b2aff [fix: writeback: Fix sync livelock due to b_dirty_time processing (v5.9)] | ||
13 | b74b25f [fix: version ranges for ext4_discard_preallocations and writeback_queue_io | ||
14 | |||
15 | Upstream-status: Backport | ||
16 | |||
17 | Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com> | ||
18 | --- | ||
19 | .../events/lttng-module/writeback.h | 48 +++++++++++++------ | ||
20 | 1 file changed, 33 insertions(+), 15 deletions(-) | ||
21 | |||
22 | diff --git a/instrumentation/events/lttng-module/writeback.h b/instrumentation/events/lttng-module/writeback.h | ||
23 | index 3327a0f..8d2250e 100644 | ||
24 | --- a/instrumentation/events/lttng-module/writeback.h | ||
25 | +++ b/instrumentation/events/lttng-module/writeback.h | ||
26 | @@ -372,34 +372,55 @@ LTTNG_TRACEPOINT_EVENT_WBC_INSTANCE(wbc_balance_dirty_wait, writeback_wbc_balanc | ||
27 | #endif | ||
28 | LTTNG_TRACEPOINT_EVENT_WBC_INSTANCE(wbc_writepage, writeback_wbc_writepage) | ||
29 | |||
30 | -#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,1,0)) | ||
31 | +#if (LINUX_VERSION_CODE >= KERNEL_VERSION(5,9,0) || \ | ||
32 | + LTTNG_KERNEL_RANGE(5,8,6, 5,9,0) || \ | ||
33 | + LTTNG_KERNEL_RANGE(5,4,62, 5,5,0) || \ | ||
34 | + LTTNG_KERNEL_RANGE(4,19,143, 4,20,0) || \ | ||
35 | + LTTNG_KERNEL_RANGE(4,14,196, 4,15,0) || \ | ||
36 | + LTTNG_KERNEL_RANGE(4,9,235, 4,10,0) || \ | ||
37 | + LTTNG_KERNEL_RANGE(4,4,235, 4,5,0) || \ | ||
38 | + LTTNG_UBUNTU_KERNEL_RANGE(4,15,18,119, 4,16,0,0)) | ||
39 | +LTTNG_TRACEPOINT_EVENT(writeback_queue_io, | ||
40 | + TP_PROTO(struct bdi_writeback *wb, | ||
41 | + struct wb_writeback_work *work, | ||
42 | + unsigned long dirtied_before, | ||
43 | + int moved), | ||
44 | + TP_ARGS(wb, work, dirtied_before, moved), | ||
45 | + TP_FIELDS( | ||
46 | + ctf_array_text(char, name, dev_name(wb->bdi->dev), 32) | ||
47 | + ctf_integer(unsigned long, older, dirtied_before) | ||
48 | + ctf_integer(int, moved, moved) | ||
49 | + ) | ||
50 | +) | ||
51 | +#elif (LINUX_VERSION_CODE >= KERNEL_VERSION(3,2,0)) | ||
52 | LTTNG_TRACEPOINT_EVENT(writeback_queue_io, | ||
53 | TP_PROTO(struct bdi_writeback *wb, | ||
54 | -#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,2,0)) | ||
55 | struct wb_writeback_work *work, | ||
56 | -#else | ||
57 | - unsigned long *older_than_this, | ||
58 | -#endif | ||
59 | int moved), | ||
60 | -#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,2,0)) | ||
61 | TP_ARGS(wb, work, moved), | ||
62 | -#else | ||
63 | + TP_FIELDS( | ||
64 | + ctf_array_text(char, name, dev_name(wb->bdi->dev), 32) | ||
65 | + ctf_integer(int, moved, moved) | ||
66 | + ) | ||
67 | +) | ||
68 | +#elif (LINUX_VERSION_CODE >= KERNEL_VERSION(3,1,0)) | ||
69 | +LTTNG_TRACEPOINT_EVENT(writeback_queue_io, | ||
70 | + TP_PROTO(struct bdi_writeback *wb, | ||
71 | + unsigned long *older_than_this, | ||
72 | + int moved), | ||
73 | TP_ARGS(wb, older_than_this, moved), | ||
74 | -#endif | ||
75 | TP_FIELDS( | ||
76 | ctf_array_text(char, name, dev_name(wb->bdi->dev), 32) | ||
77 | -#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,2,0)) | ||
78 | -#else | ||
79 | ctf_integer(unsigned long, older, | ||
80 | older_than_this ? *older_than_this : 0) | ||
81 | ctf_integer(long, age, | ||
82 | older_than_this ? | ||
83 | (jiffies - *older_than_this) * 1000 / HZ | ||
84 | : -1) | ||
85 | -#endif | ||
86 | ctf_integer(int, moved, moved) | ||
87 | ) | ||
88 | ) | ||
89 | +#endif | ||
90 | |||
91 | #if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,14,0)) | ||
92 | LTTNG_TRACEPOINT_EVENT_MAP(global_dirty_state, | ||
93 | @@ -425,7 +446,7 @@ LTTNG_TRACEPOINT_EVENT_MAP(global_dirty_state, | ||
94 | ctf_integer(unsigned long, dirty_limit, global_dirty_limit) | ||
95 | ) | ||
96 | ) | ||
97 | -#else | ||
98 | +#elif (LINUX_VERSION_CODE >= KERNEL_VERSION(3,1,0)) | ||
99 | LTTNG_TRACEPOINT_EVENT_MAP(global_dirty_state, | ||
100 | |||
101 | writeback_global_dirty_state, | ||
102 | @@ -450,7 +471,6 @@ LTTNG_TRACEPOINT_EVENT_MAP(global_dirty_state, | ||
103 | ) | ||
104 | ) | ||
105 | #endif | ||
106 | -#endif | ||
107 | |||
108 | #if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,2,0)) | ||
109 | |||
110 | @@ -661,7 +681,6 @@ LTTNG_TRACEPOINT_EVENT(writeback_sb_inodes_requeue, | ||
111 | ) | ||
112 | #endif | ||
113 | |||
114 | -#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,37)) | ||
115 | LTTNG_TRACEPOINT_EVENT_CLASS(writeback_congest_waited_template, | ||
116 | |||
117 | TP_PROTO(unsigned int usec_timeout, unsigned int usec_delayed), | ||
118 | @@ -687,7 +706,6 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE(writeback_congest_waited_template, writeback_wai | ||
119 | |||
120 | TP_ARGS(usec_timeout, usec_delayed) | ||
121 | ) | ||
122 | -#endif | ||
123 | |||
124 | #if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,1,0)) | ||
125 | LTTNG_TRACEPOINT_EVENT_CLASS(writeback_single_inode_template, | ||
126 | -- | ||
127 | 2.25.1 | ||
128 | |||
diff --git a/meta/recipes-kernel/lttng/lttng-modules_2.11.2.bb b/meta/recipes-kernel/lttng/lttng-modules_2.11.2.bb index 6fff096a37..8e56a3c10a 100644 --- a/meta/recipes-kernel/lttng/lttng-modules_2.11.2.bb +++ b/meta/recipes-kernel/lttng/lttng-modules_2.11.2.bb | |||
@@ -11,6 +11,7 @@ COMPATIBLE_HOST = '(x86_64|i.86|powerpc|aarch64|mips|nios2|arm|riscv).*-linux' | |||
11 | SRC_URI = "https://lttng.org/files/${BPN}/${BPN}-${PV}.tar.bz2 \ | 11 | SRC_URI = "https://lttng.org/files/${BPN}/${BPN}-${PV}.tar.bz2 \ |
12 | file://Makefile-Do-not-fail-if-CONFIG_TRACEPOINTS-is-not-en.patch \ | 12 | file://Makefile-Do-not-fail-if-CONFIG_TRACEPOINTS-is-not-en.patch \ |
13 | file://BUILD_RUNTIME_BUG_ON-vs-gcc7.patch \ | 13 | file://BUILD_RUNTIME_BUG_ON-vs-gcc7.patch \ |
14 | file://0001-lttng-modules-backport-writeback.h-changes-from-2.12.patch \ | ||
14 | " | 15 | " |
15 | 16 | ||
16 | SRC_URI[md5sum] = "2e3bc8cfb264fa13f374618b46f170e7" | 17 | SRC_URI[md5sum] = "2e3bc8cfb264fa13f374618b46f170e7" |
@@ -33,11 +34,11 @@ python do_package_prepend() { | |||
33 | BBCLASSEXTEND = "devupstream:target" | 34 | BBCLASSEXTEND = "devupstream:target" |
34 | LIC_FILES_CHKSUM_class-devupstream = "file://LICENSE;md5=3f882d431dc0f32f1f44c0707aa41128" | 35 | LIC_FILES_CHKSUM_class-devupstream = "file://LICENSE;md5=3f882d431dc0f32f1f44c0707aa41128" |
35 | DEFAULT_PREFERENCE_class-devupstream = "-1" | 36 | DEFAULT_PREFERENCE_class-devupstream = "-1" |
36 | SRC_URI_class-devupstream = "git://git.lttng.org/lttng-modules;branch=stable-2.11 \ | 37 | SRC_URI_class-devupstream = "git://git.lttng.org/lttng-modules;branch=stable-2.12 \ |
37 | file://Makefile-Do-not-fail-if-CONFIG_TRACEPOINTS-is-not-en.patch \ | 38 | file://Makefile-Do-not-fail-if-CONFIG_TRACEPOINTS-is-not-en.patch \ |
38 | file://BUILD_RUNTIME_BUG_ON-vs-gcc7.patch \ | 39 | file://BUILD_RUNTIME_BUG_ON-vs-gcc7.patch \ |
39 | " | 40 | " |
40 | SRCREV_class-devupstream = "17c413953603f063f2a9d6c3788bec914ce6f955" | 41 | SRCREV_class-devupstream = "01a12501e0b0395b60c7e392cb7dded51ae572ca" |
41 | PV_class-devupstream = "2.11.2+git${SRCPV}" | 42 | PV_class-devupstream = "2.12.2+git${SRCPV}" |
42 | S_class-devupstream = "${WORKDIR}/git" | 43 | S_class-devupstream = "${WORKDIR}/git" |
43 | SRCREV_FORMAT ?= "lttng_git" | 44 | SRCREV_FORMAT ?= "lttng_git" |