Re: [PATCH] workqueue: doc: Call out the non-reentrance conditions

From
Tejun Heo <tj@kernel.org>
Date
2021-10-20 16:18:25
Also in
lkml
Reply to
Boqun Feng, 2021-10-20
On Wed, Oct 20, 2021 at 01:40:21PM +0800, Boqun Feng wrote:
* A work item instance will not be processed by multiple workers at the
  same time, i.e. it's non-reentrant, so requeuing the same instance of
  a work item is safe and not racy.  Operations considered as changing
  the work item to a different instance are: 1) change the work
  function, 2) queue the work item to a different workqueue, or 3)
  reinitiate the work item.  The non-reentrance guarantee doesn't hold
  for different work item instances.
Yeah, I prefer it to be described this way but it's not a strong opinion.
Looks good to me either way.

Thanks.

-- 
tejun
Thread (7 messages) 7 messages, 3 authors, last reply 2021-10-20
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help