diff options
author | Tejun Heo <tj@kernel.org> | 2013-03-13 16:51:35 -0700 |
---|---|---|
committer | Tejun Heo <tj@kernel.org> | 2013-03-13 16:51:35 -0700 |
commit | 699ce097efe8f45bc5c055e4f12cb1e271c270d9 (patch) | |
tree | db116c908ed97eaf621c4dc99a4896acd51e56a2 /kernel/Makefile | |
parent | 0fbd95aa8a056194933fba4ae78c50fc20f0704e (diff) |
workqueue: implement and use pwq_adjust_max_active()
Rename pwq_set_max_active() to pwq_adjust_max_active() and move
pool_workqueue->max_active synchronization and max_active
determination logic into it.
The new function should be called with workqueue_lock held for stable
workqueue->saved_max_active, determines the current max_active value
the target pool_workqueue should be using from @wq->saved_max_active
and the state of the associated pool, and applies it with proper
synchronization.
The current two users - workqueue_set_max_active() and
thaw_workqueues() - are updated accordingly. In addition, the manual
freezing handling in __alloc_workqueue_key() and
freeze_workqueues_begin() are replaced with calls to
pwq_adjust_max_active().
This centralizes max_active handling so that it's less error-prone.
Signed-off-by: Tejun Heo <tj@kernel.org>
Diffstat (limited to 'kernel/Makefile')
0 files changed, 0 insertions, 0 deletions