Re: 回复: [PATCH v5] workqueue: Remove unnecessary kfree() call in rcu_free_wq()

2020-05-28 Thread Dan Carpenter
On Thu, May 28, 2020 at 09:27:03PM +0800, Lai Jiangshan wrote: > On Thu, May 28, 2020 at 8:27 PM Dan Carpenter > wrote: > > > > On Thu, May 28, 2020 at 08:08:06PM +0800, Lai Jiangshan wrote: > > > On Thu, May 28, 2020 at 5:57 PM Dan Carpenter > > > wrote: > > > > > > > > Guys, the patch is

Re: 回复: [PATCH v5] workqueue: Remove unnecessary kfree() call in rcu_free_wq()

2020-05-28 Thread Tejun Heo
Hello, On Thu, May 28, 2020 at 09:27:03PM +0800, Lai Jiangshan wrote: > wq owns the ultimate or permanent references to itself by > owning references to wq->numa_pwq_tbl[node], wq->dfl_pwq. > The pwq's references keep the pwq in wq->pwqs. Yeah, regardless of who puts a wq the last time, the base

Re: 回复: [PATCH v5] workqueue: Remove unnecessary kfree() call in rcu_free_wq()

2020-05-28 Thread Lai Jiangshan
On Thu, May 28, 2020 at 8:27 PM Dan Carpenter wrote: > > On Thu, May 28, 2020 at 08:08:06PM +0800, Lai Jiangshan wrote: > > On Thu, May 28, 2020 at 5:57 PM Dan Carpenter > > wrote: > > > > > > Guys, the patch is wrong. The kfree is harmless when this is called > > > from destroy_workqueue()

Re: 回复: [PATCH v5] workqueue: Remove unnecessary kfree() call in rcu_free_wq()

2020-05-28 Thread Dan Carpenter
On Thu, May 28, 2020 at 08:08:06PM +0800, Lai Jiangshan wrote: > On Thu, May 28, 2020 at 5:57 PM Dan Carpenter > wrote: > > > > Guys, the patch is wrong. The kfree is harmless when this is called > > from destroy_workqueue() and required when it's called from > > pwq_unbound_release_workfn().

Re: 回复: [PATCH v5] workqueue: Remove unnecessary kfree() call in rcu_free_wq()

2020-05-28 Thread Lai Jiangshan
On Thu, May 28, 2020 at 5:57 PM Dan Carpenter wrote: > > Guys, the patch is wrong. The kfree is harmless when this is called > from destroy_workqueue() and required when it's called from > pwq_unbound_release_workfn(). Lai Jiangshan already explained this > already. Why are we still discussing

Re: 回复: [PATCH v5] workqueue: Remove unnecessary kfree() call in rcu_free_wq()

2020-05-28 Thread Tejun Heo
On Thu, May 28, 2020 at 12:57:03PM +0300, Dan Carpenter wrote: > Guys, the patch is wrong. The kfree is harmless when this is called > from destroy_workqueue() and required when it's called from > pwq_unbound_release_workfn(). Lai Jiangshan already explained this > already. Why are we still

Re: 回复: [PATCH v5] workqueue: Remove unnecessary kfree() call in rcu_free_wq()

2020-05-28 Thread Dan Carpenter
Guys, the patch is wrong. The kfree is harmless when this is called from destroy_workqueue() and required when it's called from pwq_unbound_release_workfn(). Lai Jiangshan already explained this already. Why are we still discussing this? regards, dan carpenter

回复: [PATCH v5] workqueue: Remove unnecessary kfree() call in rcu_free_wq()

2020-05-27 Thread Zhang, Qiang
Thanks for your guide. I will try to change the weakness of weak wording. 发件人: Zhang, Qiang 发送时间: 2020年5月28日 9:41 收件人: Markus Elfring; Tejun Heo; Lai Jiangshan 抄送: linux-kernel@vger.kernel.org; kernel-janit...@vger.kernel.org 主题: 回复: [PATCH v5] workqueue