All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Naveen N. Rao" <naveen.n.rao@linux.vnet.ibm.com>
To: Masami Hiramatsu <mhiramat@kernel.org>
Cc: Akanksha J N <akanksha@linux.vnet.ibm.com>,
	linux-kernel@vger.kernel.org,
	Steven Rostedt <rostedt@goodmis.org>,
	Shuah Khan <shuah@kernel.org>
Subject: Re: [PATCH] selftests/ftrace: Limit number of lines processed in 'trace'
Date: Fri, 28 Oct 2022 12:59:54 +0530	[thread overview]
Message-ID: <1666941493.vogf5bjzvv.naveen@linux.ibm.com> (raw)
In-Reply-To: <20221020004607.a78c771e12ad0f65c018220b@kernel.org>

Masami Hiramatsu wrote:
> On Wed, 19 Oct 2022 15:15:09 +0530
> "Naveen N. Rao" <naveen.n.rao@linux.vnet.ibm.com> wrote:
> 
>> Steven Rostedt wrote:
>> > On Wed, 19 Oct 2022 00:19:49 +0900
>> > Masami Hiramatsu (Google) <mhiramat@kernel.org> 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?

This was reported in internal tests with RHEL kernel.

> 
>> 
>> 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.

This patch doesn't seem to be enough - event/subsystem-enable.tc also 
needs updates. In light of that, I'm not sure if the large number of 
disable_tracing statements required makes sense. So, I'm inclined to 
drop this patch in favour of the existing pause-on-trace option.


Thanks,
Naveen

  reply	other threads:[~2022-10-28  7:30 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-10-17 10:55 [PATCH] selftests/ftrace: Limit number of lines processed in 'trace' Naveen N. Rao
2022-10-17 14:51 ` Steven Rostedt
2022-10-18 15:19   ` Masami Hiramatsu
2022-10-18 15:22     ` Steven Rostedt
2022-10-19  9:45       ` Naveen N. Rao
2022-10-19 15:46         ` Masami Hiramatsu
2022-10-28  7:29           ` Naveen N. Rao [this message]
2022-10-18 22:41 ` Shuah Khan

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1666941493.vogf5bjzvv.naveen@linux.ibm.com \
    --to=naveen.n.rao@linux.vnet.ibm.com \
    --cc=akanksha@linux.vnet.ibm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mhiramat@kernel.org \
    --cc=rostedt@goodmis.org \
    --cc=shuah@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.