mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Tejun Heo <tj@kernel.org>
To: Lai Jiangshan <laijs@cn.fujitsu.com>
Cc: linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/3] workqueue: extend wq_pool_mutex to also protect pwq-installation
Date: Mon, 27 Oct 2014 09:20:47 -0400	[thread overview]
Message-ID: <20141027132047.GE4436@htj.dyndns.org> (raw)
In-Reply-To: <1412740423-20782-3-git-send-email-laijs@cn.fujitsu.com>

Hello, Lai.

On Wed, Oct 08, 2014 at 11:53:32AM +0800, Lai Jiangshan wrote:
> Athough pwq-installation without wq_pool_mutex held is not bug,
> but it is not good design, it is better to make the pwq-allocation and installation
> are in the (same) wq_pool_mutex.

WHY?  Why is that not a good design and why is extending the locking a
better thing to do?  Can you elaborate the reasoning here?

> And since the pwq-allocation and installation are in the same wq_pool_mutex,
> get_online_cpus() will not be needed for this reason, and it will be remove
> in later patch.

So, if this enables further cleanup, it's fine, but please just stick
to those reasons.  You do this a lot.  You wanna do A because of B but
the changelog often doesn't mention that at all and just goes "This is
bad so change this to be better" without any proper reasoning.  If you
want to do A to achieve B later, just say so.

Thanks.

-- 
tejun

  reply	other threads:[~2014-10-27 13:20 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-10-08  3:53 [PATCH 0/3] workqueue: unbound workqueue management Vs hotplug Lai Jiangshan
2014-10-08  3:53 ` [PATCH 1/3] workqueue: add wq_unbound_online_cpumask Lai Jiangshan
2014-10-27 13:15   ` Tejun Heo
2014-10-08  3:53 ` [PATCH 2/3] workqueue: extend wq_pool_mutex to also protect pwq-installation Lai Jiangshan
2014-10-27 13:20   ` Tejun Heo [this message]
2014-10-08  3:53 ` [PATCH 3/3] workqueue: remove get_online_cpus() from apply_workqueue_attrs() Lai Jiangshan
2014-10-27 13:41   ` Tejun Heo
2014-10-27  9:27 ` [PATCH 0/3] workqueue: unbound workqueue management Vs hotplug Lai Jiangshan

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=20141027132047.GE4436@htj.dyndns.org \
    --to=tj@kernel.org \
    --cc=laijs@cn.fujitsu.com \
    --cc=linux-kernel@vger.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®