On Wed, 19 Oct 2022 15:15:09 +0530
"Naveen N. Rao" <naveen.n.rao@xxxxxxxxxxxxxxxxxx> wrote:
Steven Rostedt wrote:
> On Wed, 19 Oct 2022 00:19:49 +0900
> Masami Hiramatsu (Google) <mhiramat@xxxxxxxxxx> wrote:
> >> > You need to make sure that the "pause-on-trace" option is set or tracing_on
>> > is set to 0 (disabled). Otherwise, if the tracing is still active, then the
>> > reading of the trace file could potentially never end. >> >> initialize_ftrace() does this setting. So it must be set.
>> If you run the ftracetest on old kernel, this feature is not there and
>> it may cause a trouble. Naveen, can you clarify it?
Yes, the change to not pause on opening the trace file looks to be the problem.
> > But for old kernels that do not have "pause-on-trace" it should be the
> default. The "pause-on-trace" was added when the default was changed to not
> pause the trace while reading it.
It looks like the kernel patch was picked up, but Masami's patch for the selftest wasn't backported. I have requested a test with that applied.
Good! That should be backported too.
BTW, which kernel version do you test?
Separately, before I saw your response, I came up with the below patch to update the selftests to disable tracing before reading the trace file. I have also requested this to be tested.
Yeah, OK. This also looks OK to me.