summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorTejun Heo <tj@kernel.org>2024-02-09 03:11:56 +0300
committerTejun Heo <tj@kernel.org>2024-02-10 00:13:59 +0300
commit8f172181f24bb5df7675225d9b5b66d059613f50 (patch)
tree1d3d37638d3aa6f2193e68017b69b10f65e55b2f /include
parent516d3dc99f4f2ab856d879696cd3a5d7f6db7796 (diff)
downloadlinux-8f172181f24bb5df7675225d9b5b66d059613f50.tar.xz
workqueue: Implement workqueue_set_min_active()
Since 5797b1c18919 ("workqueue: Implement system-wide nr_active enforcement for unbound workqueues"), unbound workqueues have separate min_active which sets the number of interdependent work items that can be handled. This value is currently initialized to WQ_DFL_MIN_ACTIVE which is 8. This isn't high enough for some users, let's add an interface to adjust the setting. Signed-off-by: Tejun Heo <tj@kernel.org>
Diffstat (limited to 'include')
-rw-r--r--include/linux/workqueue.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/workqueue.h b/include/linux/workqueue.h
index 4ba33cf07f11..1565bab9edc8 100644
--- a/include/linux/workqueue.h
+++ b/include/linux/workqueue.h
@@ -553,6 +553,8 @@ extern bool flush_rcu_work(struct rcu_work *rwork);
extern void workqueue_set_max_active(struct workqueue_struct *wq,
int max_active);
+extern void workqueue_set_min_active(struct workqueue_struct *wq,
+ int min_active);
extern struct work_struct *current_work(void);
extern bool current_is_workqueue_rescuer(void);
extern bool workqueue_congested(int cpu, struct workqueue_struct *wq);