Skip to content
Commit bad184d2 authored by Tejun Heo's avatar Tejun Heo Committed by Sasha Levin
Browse files

workqueue: Factor out pwq_is_empty()



[ Upstream commit afa87ce8 ]

"!pwq->nr_active && list_empty(&pwq->inactive_works)" test is repeated
multiple times. Let's factor it out into pwq_is_empty().

Signed-off-by: default avatarTejun Heo <tj@kernel.org>
Reviewed-by: default avatarLai Jiangshan <jiangshanlai@gmail.com>
Stable-dep-of: 5797b1c1 ("workqueue: Implement system-wide nr_active enforcement for unbound workqueues")
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
parent 82e098f5
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment