diff options
Diffstat (limited to 'meta/recipes-kernel/lttng/lttng-modules/0003-Fix-strlcopy-removed-in-linux-6.8.0-rc1.patch')
-rw-r--r-- | meta/recipes-kernel/lttng/lttng-modules/0003-Fix-strlcopy-removed-in-linux-6.8.0-rc1.patch | 46 |
1 files changed, 0 insertions, 46 deletions
diff --git a/meta/recipes-kernel/lttng/lttng-modules/0003-Fix-strlcopy-removed-in-linux-6.8.0-rc1.patch b/meta/recipes-kernel/lttng/lttng-modules/0003-Fix-strlcopy-removed-in-linux-6.8.0-rc1.patch deleted file mode 100644 index 4ad9adc5c2..0000000000 --- a/meta/recipes-kernel/lttng/lttng-modules/0003-Fix-strlcopy-removed-in-linux-6.8.0-rc1.patch +++ /dev/null | |||
@@ -1,46 +0,0 @@ | |||
1 | From 7432f583674294b676577b6505b89fc74dc5c7ab Mon Sep 17 00:00:00 2001 | ||
2 | From: Kienan Stewart <kstewart@efficios.com> | ||
3 | Date: Mon, 22 Jan 2024 11:47:40 -0500 | ||
4 | Subject: [PATCH 3/5] Fix: strlcopy removed in linux 6.8.0-rc1 | ||
5 | |||
6 | See upstream commit: | ||
7 | |||
8 | commit d26270061ae66b915138af7cd73ca6f8b85e6b44 | ||
9 | Author: Kees Cook <keescook@chromium.org> | ||
10 | Date: Thu Jan 18 12:31:55 2024 -0800 | ||
11 | |||
12 | string: Remove strlcpy() | ||
13 | |||
14 | With all the users of strlcpy() removed[1] from the kernel, remove the | ||
15 | API, self-tests, and other references. Leave mentions in Documentation | ||
16 | (about its deprecation), and in checkpatch.pl (to help migrate host-only | ||
17 | tools/ usage). Long live strscpy(). | ||
18 | |||
19 | Upstream-Status: Backport [Uhttps://review.lttng.org/c/lttng-modules/+/11700] | ||
20 | |||
21 | Change-Id: I27cdff70a504b25340cc59150ed8e959d9629e43 | ||
22 | Signed-off-by: Kienan Stewart <kstewart@efficios.com> | ||
23 | Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com> | ||
24 | --- | ||
25 | src/lib/ringbuffer/ring_buffer_backend.c | 4 ++++ | ||
26 | 1 file changed, 4 insertions(+) | ||
27 | |||
28 | diff --git a/src/lib/ringbuffer/ring_buffer_backend.c b/src/lib/ringbuffer/ring_buffer_backend.c | ||
29 | index 9a339be..2181145 100644 | ||
30 | --- a/src/lib/ringbuffer/ring_buffer_backend.c | ||
31 | +++ b/src/lib/ringbuffer/ring_buffer_backend.c | ||
32 | @@ -405,7 +405,11 @@ int channel_backend_init(struct channel_backend *chanb, | ||
33 | chanb->extra_reader_sb = | ||
34 | (config->mode == RING_BUFFER_OVERWRITE) ? 1 : 0; | ||
35 | chanb->num_subbuf = num_subbuf; | ||
36 | +#if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(6,8,0)) | ||
37 | + strscpy(chanb->name, name, NAME_MAX); | ||
38 | +#else | ||
39 | strlcpy(chanb->name, name, NAME_MAX); | ||
40 | +#endif | ||
41 | memcpy(&chanb->config, config, sizeof(chanb->config)); | ||
42 | |||
43 | if (config->alloc == RING_BUFFER_ALLOC_PER_CPU) { | ||
44 | -- | ||
45 | 2.39.2 | ||
46 | |||