All of lore.kernel.org
 help / color / mirror / Atom feed
From: Peter Zijlstra <peterz@infradead.org>
To: Tejun Heo <tj@kernel.org>
Cc: Sebastian Andrzej Siewior <bigeasy@linutronix.de>,
	linux-kernel@vger.kernel.org,
	Lai Jiangshan <jiangshanlai@gmail.com>,
	Ingo Molnar <mingo@kernel.org>,
	Thomas Gleixner <tglx@linutronix.de>,
	Daniel Bristot de Oliveira <bristot@redhat.com>
Subject: Re: [PATCH 2/2] sched: Distangle worker accounting from rq lock
Date: Tue, 9 Apr 2019 10:22:50 +0200	[thread overview]
Message-ID: <20190409082250.GY12232@hirez.programming.kicks-ass.net> (raw)
In-Reply-To: <20190408194505.GK1975820@devbig004.ftw2.facebook.com>

On Mon, Apr 08, 2019 at 12:45:05PM -0700, Tejun Heo wrote:
> Hello,
> 
> On Wed, Mar 13, 2019 at 05:55:48PM +0100, Sebastian Andrzej Siewior wrote:
> > From: Thomas Gleixner <tglx@linutronix.de>
> > 
> > The worker accounting for CPU bound workers is plugged into the core
> > scheduler code and the wakeup code. This is not a hard requirement and
> > can be avoided by keeping track of the state in the workqueue code
> > itself.
> > 
> > Keep track of the sleeping state in the worker itself and call the
> > notifier before entering the core scheduler. There might be false
> > positives when the task is woken between that call and actually
> > scheduling, but that's not really different from scheduling and being
> > woken immediately after switching away. When nr_running is updated when
> > the task is retunrning from schedule() then it is later compared when it
> > is done from ttwu().
> > 
> > Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
> > Cc: Daniel Bristot de Oliveira <bristot@redhat.com>
> > Link: http://lkml.kernel.org/r/20110622174919.135236139@linutronix.de
> > Link: http://lkml.kernel.org/r/ad2b29b5715f970bffc1a7026cabd6ff0b24076a.1532952814.git.bristot@redhat.com
> > Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
> > [bigeasy: preempt_disable() around wq_worker_sleeping() by Daniel Bristot de
> >           Oliveira]
> > Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
> 
> This looks good from wq side.  Peter, are you okay with routing this
> through the wq tree?  If you wanna take it through the sched tree,
> please feel free to add
> 
> Acked-by: Tejun Heo <tj@kernel.org>

If you don't mind I'll take it through the sched tree, because while
looking at it I did a few cleanups on top.

Thanks!

      parent reply	other threads:[~2019-04-09  8:23 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-03-13 16:55 [PATCH 0/2] workqueue: use normal RCU and don't depend on the rq lock Sebastian Andrzej Siewior
2019-03-13 16:55 ` [PATCH 1/2] workqueue: Use normal rcu Sebastian Andrzej Siewior
2019-03-21 20:59   ` Sebastian Andrzej Siewior
2019-03-22 17:43     ` Tejun Heo
2019-03-22 17:59       ` Sebastian Andrzej Siewior
2019-04-05 14:42         ` Sebastian Andrzej Siewior
2019-04-08 15:10           ` Tejun Heo
2019-04-08 19:38   ` Tejun Heo
2019-03-13 16:55 ` [PATCH 2/2] sched: Distangle worker accounting from rq lock Sebastian Andrzej Siewior
2019-04-08 19:45   ` Tejun Heo
2019-04-09  7:33     ` Sebastian Andrzej Siewior
2019-04-09  8:22     ` Peter Zijlstra [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=20190409082250.GY12232@hirez.programming.kicks-ass.net \
    --to=peterz@infradead.org \
    --cc=bigeasy@linutronix.de \
    --cc=bristot@redhat.com \
    --cc=jiangshanlai@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@kernel.org \
    --cc=tglx@linutronix.de \
    --cc=tj@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.