.../ftrace/test.d/00basic/trace_marker_raw.tc | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-)
When /sys/kernel/tracing/buffer_size_kb is less than 12KB,
the test_multiple_writes test will stall and wait for more
input due to insufficient buffer space.
Check current buffer_size_kb value before the test. If it is
less than 12KB, it temporarily increase the buffer to 12KB,
and restore the original value after the tests are completed.
Fixes: 37f46601383a ("selftests/tracing: Add basic test for trace_marker_raw file")
Suggested-by: Steven Rostedt <rostedt@goodmis.org>
Signed-off-by: Fushuai Wang <wangfushuai@baidu.com>
---
V1 -> V2: Restore buffer_size_kb outside of awk script.
.../ftrace/test.d/00basic/trace_marker_raw.tc | 18 +++++++++++++++++-
1 file changed, 17 insertions(+), 1 deletion(-)
diff --git a/tools/testing/selftests/ftrace/test.d/00basic/trace_marker_raw.tc b/tools/testing/selftests/ftrace/test.d/00basic/trace_marker_raw.tc
index 7daf7292209e..a2c42e13f614 100644
--- a/tools/testing/selftests/ftrace/test.d/00basic/trace_marker_raw.tc
+++ b/tools/testing/selftests/ftrace/test.d/00basic/trace_marker_raw.tc
@@ -89,6 +89,7 @@ test_buffer() {
# The id must be four bytes, test that 3 bytes fails a write
if echo -n abc > ./trace_marker_raw ; then
echo "Too small of write expected to fail but did not"
+ echo ${ORIG} > buffer_size_kb
exit_fail
fi
@@ -99,9 +100,24 @@ test_buffer() {
if write_buffer 0xdeadbeef $size ; then
echo "Too big of write expected to fail but did not"
+ echo ${ORIG} > buffer_size_kb
exit_fail
fi
}
+ORIG=`cat buffer_size_kb`
+
+# test_multiple_writes test needs at least 12KB buffer
+NEW_SIZE=12
+
+if [ ${ORIG} -lt ${NEW_SIZE} ]; then
+ echo ${NEW_SIZE} > buffer_size_kb
+fi
+
test_buffer
-test_multiple_writes
+if ! test_multiple_writes; then
+ echo ${ORIG} > buffer_size_kb
+ exit_fail
+fi
+
+echo ${ORIG} > buffer_size_kb
--
2.36.1
> When /sys/kernel/tracing/buffer_size_kb is less than 12KB,
> the test_multiple_writes test will stall and wait for more
> input due to insufficient buffer space.
>
> Check current buffer_size_kb value before the test. If it is
> less than 12KB, it temporarily increase the buffer to 12KB,
> and restore the original value after the tests are completed.
>
> Fixes: 37f46601383a ("selftests/tracing: Add basic test for trace_marker_raw file")
> Suggested-by: Steven Rostedt <rostedt@goodmis.org>
> Signed-off-by: Fushuai Wang <wangfushuai@baidu.com>
Gentle ping.
---
Regards,
WANG
On Wed, 7 Jan 2026 11:49:14 +0800
Fushuai Wang <fushuai.wang@linux.dev> wrote:
> > When /sys/kernel/tracing/buffer_size_kb is less than 12KB,
> > the test_multiple_writes test will stall and wait for more
> > input due to insufficient buffer space.
> >
> > Check current buffer_size_kb value before the test. If it is
> > less than 12KB, it temporarily increase the buffer to 12KB,
> > and restore the original value after the tests are completed.
> >
> > Fixes: 37f46601383a ("selftests/tracing: Add basic test for trace_marker_raw file")
> > Suggested-by: Steven Rostedt <rostedt@goodmis.org>
> > Signed-off-by: Fushuai Wang <wangfushuai@baidu.com>
>
> Gentle ping.
>
Acked-by: Steven Rostedt (Google) <rostedt@goodmis.org>
Shuah,
Care to take this through your tree? It does fix a bug so it likely should
go into the rc releases and not wait for the next merge window.
Thanks,
-- Steve
On 1/7/26 08:18, Steven Rostedt wrote:
> On Wed, 7 Jan 2026 11:49:14 +0800
> Fushuai Wang <fushuai.wang@linux.dev> wrote:
>
>>> When /sys/kernel/tracing/buffer_size_kb is less than 12KB,
>>> the test_multiple_writes test will stall and wait for more
>>> input due to insufficient buffer space.
>>>
>>> Check current buffer_size_kb value before the test. If it is
>>> less than 12KB, it temporarily increase the buffer to 12KB,
>>> and restore the original value after the tests are completed.
>>>
>>> Fixes: 37f46601383a ("selftests/tracing: Add basic test for trace_marker_raw file")
>>> Suggested-by: Steven Rostedt <rostedt@goodmis.org>
>>> Signed-off-by: Fushuai Wang <wangfushuai@baidu.com>
>>
>> Gentle ping.
>>
>
> Acked-by: Steven Rostedt (Google) <rostedt@goodmis.org>
>
> Shuah,
>
> Care to take this through your tree? It does fix a bug so it likely should
> go into the rc releases and not wait for the next merge window.
>
Yes I can take this through and send this for rc5 or rc6.
But first the following warning needs fixing before I can
apply the patch
WARNING: From:/Signed-off-by: email address mismatch: 'From: Fushuai Wang <fushuai.wang@linux.dev>' != 'Signed-off-by: Fushuai Wang <wangfushuai@baidu.com>'
Fushuai, please send me v3
thanks,
-- Shuah
On Thu, 8 Jan 2026 11:27:26 -0700 Shuah <shuah@kernel.org> wrote: > Yes I can take this through and send this for rc5 or rc6. > But first the following warning needs fixing before I can > apply the patch > > WARNING: From:/Signed-off-by: email address mismatch: 'From: Fushuai Wang <fushuai.wang@linux.dev>' != 'Signed-off-by: Fushuai Wang <wangfushuai@baidu.com>' Hmm, do emails have to match? There's times I used a different SoB than the From. The From is different than the SoB. The important part I found was to make sure the name is the same. But I didn't think the email address was important. And this will become more of an issue, as gmail blocks my goodmis.org account, so I send with my kernel.org account when my goodmis is the only one I sign off with. Thus this restriction will fail for me on my patches. -- Steve
On 1/8/26 12:48, Steven Rostedt wrote: > On Thu, 8 Jan 2026 11:27:26 -0700 > Shuah <shuah@kernel.org> wrote: > >> Yes I can take this through and send this for rc5 or rc6. >> But first the following warning needs fixing before I can >> apply the patch >> >> WARNING: From:/Signed-off-by: email address mismatch: 'From: Fushuai Wang <fushuai.wang@linux.dev>' != 'Signed-off-by: Fushuai Wang <wangfushuai@baidu.com>' > > Hmm, do emails have to match? There's times I used a different SoB than the > From. The From is different than the SoB. The important part I found was to > make sure the name is the same. But I didn't think the email address was > important. And this will become more of an issue, as gmail blocks my > goodmis.org account, so I send with my kernel.org account when my goodmis > is the only one I sign off with. Thus this restriction will fail for me on > my patches. I go by the warning - I don't take patches unless From address matches the SoB. thanks, -- Shuah
On Thu, 8 Jan 2026 14:03:31 -0700 Shuah Khan <skhan@linuxfoundation.org> wrote: > On 1/8/26 12:48, Steven Rostedt wrote: > > On Thu, 8 Jan 2026 11:27:26 -0700 > > Shuah <shuah@kernel.org> wrote: > > > >> Yes I can take this through and send this for rc5 or rc6. > >> But first the following warning needs fixing before I can > >> apply the patch > >> > >> WARNING: From:/Signed-off-by: email address mismatch: 'From: Fushuai Wang <fushuai.wang@linux.dev>' != 'Signed-off-by: Fushuai Wang <wangfushuai@baidu.com>' > > > > Hmm, do emails have to match? There's times I used a different SoB than the > > From. The From is different than the SoB. The important part I found was to > > make sure the name is the same. But I didn't think the email address was > > important. And this will become more of an issue, as gmail blocks my > > goodmis.org account, so I send with my kernel.org account when my goodmis > > is the only one I sign off with. Thus this restriction will fail for me on > > my patches. > > I go by the warning - I don't take patches unless From address > matches the SoB. I guess my patches would then fail your requirements ;-) Anyway, Fushuai, you can add to the top of your commit: From: Fushuai Wang <wangfushuai@baidu.com> and that will make the From and SoB match without having to change your mail client. I usually have that. Because Linus doesn't like my patches having my company name in it for the "author" but I have it in the SoB to give credit to the one paying me to do the work. -- Steve
> Anyway, Fushuai, you can add to the top of your commit: > > From: Fushuai Wang <wangfushuai@baidu.com> > > and that will make the From and SoB match without having to change your > mail client. I usually have that. Because Linus doesn't like my patches > having my company name in it for the "author" but I have it in the SoB to > give credit to the one paying me to do the work. Thanks! I will send a v3 shortly. --- Regards, WANG
© 2016 - 2026 Red Hat, Inc.