All of lore.kernel.org
 help / color / mirror / Atom feed
From: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
To: Valentin Schneider <valentin.schneider@arm.com>
Cc: linux-kernel@vger.kernel.org,
	"Abhijeet Dharmapurikar" <adharmap@quicinc.com>,
	"Uwe Kleine-König" <u.kleine-koenig@pengutronix.de>,
	"Dietmar Eggemann" <dietmar.eggemann@arm.com>,
	"Steven Rostedt" <rostedt@goodmis.org>,
	"Peter Zijlstra" <peterz@infradead.org>,
	"Ingo Molnar" <mingo@kernel.org>,
	"Vincent Guittot" <vincent.guittot@linaro.org>,
	"Thomas Gleixner" <tglx@linutronix.de>,
	"Juri Lelli" <juri.lelli@redhat.com>,
	"Daniel Bristot de Oliveira" <bristot@redhat.com>,
	"Kees Cook" <keescook@chromium.org>,
	"Andrew Morton" <akpm@linux-foundation.org>
Subject: Re: [RFC PATCH 2/2] sched/tracing: Add TASK_RTLOCK_WAIT to TASK_REPORT
Date: Fri, 14 Jan 2022 11:11:08 +0100	[thread overview]
Message-ID: <YeFMPNnCpiw9fs7e@linutronix.de> (raw)
In-Reply-To: <20211129123601.2101873-3-valentin.schneider@arm.com>

On 2021-11-29 12:36:01 [+0000], Valentin Schneider wrote:
> TASK_RTLOCK_WAIT currently isn't part of TASK_REPORT, thus a task blocking
> on an rtlock will appear as having a task state == 0, IOW TASK_RUNNING.
> 
> The actual state is saved in p->saved_state, but reading it after reading
> p->__state has a few issues:
> o that could still be TASK_RUNNING in the case of e.g. rt_spin_lock
> o ttwu_state_match() might have changed that to TASK_RUNNING
> 
> Add TASK_RTLOCK_WAIT to TASK_REPORT.
> 
> Signed-off-by: Valentin Schneider <valentin.schneider@arm.com>

We used to have the D state which was used in the locked case and was
sufficient. With the rework to TASK_RTLOCK_WAIT (which made other things
easier) we lost that. It makes debuging/ looking into the system more
obvious or does not hide things so why not.

Reviewed-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>

Sebastian

      parent reply	other threads:[~2022-01-14 10:11 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-11-29 12:35 [RFC PATCH 0/2] sched/tracing: sched_switch prev_state reported as TASK_RUNNING when it's not Valentin Schneider
2021-11-29 12:36 ` [RFC PATCH 1/2] sched/tracing: Don't re-read p->state when emitting sched_switch event Valentin Schneider
2021-11-29 16:39   ` kernel test robot
2021-11-29 16:39     ` kernel test robot
2021-11-29 16:59   ` kernel test robot
2021-11-29 16:59     ` kernel test robot
2021-12-08 20:12   ` Steven Rostedt
2021-12-09 13:02     ` Valentin Schneider
2021-11-29 12:36 ` [RFC PATCH 2/2] sched/tracing: Add TASK_RTLOCK_WAIT to TASK_REPORT Valentin Schneider
2021-12-08 20:34   ` Steven Rostedt
2022-01-14 10:11   ` Sebastian Andrzej Siewior [this message]

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=YeFMPNnCpiw9fs7e@linutronix.de \
    --to=bigeasy@linutronix.de \
    --cc=adharmap@quicinc.com \
    --cc=akpm@linux-foundation.org \
    --cc=bristot@redhat.com \
    --cc=dietmar.eggemann@arm.com \
    --cc=juri.lelli@redhat.com \
    --cc=keescook@chromium.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@kernel.org \
    --cc=peterz@infradead.org \
    --cc=rostedt@goodmis.org \
    --cc=tglx@linutronix.de \
    --cc=u.kleine-koenig@pengutronix.de \
    --cc=valentin.schneider@arm.com \
    --cc=vincent.guittot@linaro.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.