linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Tejun Heo <tj@kernel.org>
To: Yang Yingliang <yangyingliang@huawei.com>
Cc: linux-kernel@vger.kernel.org, jiangshanlai@gmail.com,
	xuqiang36@huawei.com, paskripkin@gmail.com
Subject: Re: [PATCH v3] workqueue: fix UAF in pwq_unbound_release_workfn()
Date: Fri, 16 Jul 2021 06:14:29 -1000	[thread overview]
Message-ID: <YPGwZVsE0AmkpziS@mtj.duckdns.org> (raw)
In-Reply-To: <20210714091934.3124170-1-yangyingliang@huawei.com>

On Wed, Jul 14, 2021 at 05:19:33PM +0800, Yang Yingliang wrote:
> If apply_wqattrs_prepare() fails, the new pwq are not linked, it doesn't
> hold any reference to the 'wq', 'wq' is invalid to access in the worker,
> so add check pwq if linked to fix this.
> 
> Fixes: 2d5f0764b526 ("workqueue: split apply_workqueue_attrs() into 3 stages")
> Reported-by: Hulk Robot <hulkci@huawei.com>
> Suggested-by: Lai Jiangshan <jiangshanlai@gmail.com>
> Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>

Applied to wq/for-5.14-fixes.

Thanks.

-- 
tejun

      parent reply	other threads:[~2021-07-16 16:14 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-07-14  9:19 [PATCH v3] workqueue: fix UAF in pwq_unbound_release_workfn() Yang Yingliang
2021-07-15  8:08 ` Lai Jiangshan
2021-07-15 18:52   ` Pavel Skripkin
2021-07-16 10:45     ` Pavel Skripkin
2021-07-16 16:14 ` Tejun Heo [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=YPGwZVsE0AmkpziS@mtj.duckdns.org \
    --to=tj@kernel.org \
    --cc=jiangshanlai@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=paskripkin@gmail.com \
    --cc=xuqiang36@huawei.com \
    --cc=yangyingliang@huawei.com \
    /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;
as well as URLs for NNTP newsgroup(s).