lkml.org 
[lkml]   [2025]   [Sep]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH] workqueue: Remove rcu_read_lock/unlock() in wq_watchdog_timer_fn()
Date
The wq_watchdog_timer_fn() is executed in the softirq context, this
is already in the RCU read critical section, this commit therefore
remove rcu_read_lock/unlock() in wq_watchdog_timer_fn().

Signed-off-by: Zqiang <qiang.zhang@linux.dev>
---
kernel/workqueue.c | 4 ----
1 file changed, 4 deletions(-)

diff --git a/kernel/workqueue.c b/kernel/workqueue.c
index 831754e90071..63b2685c2cb4 100644
--- a/kernel/workqueue.c
+++ b/kernel/workqueue.c
@@ -7544,8 +7544,6 @@ static void wq_watchdog_timer_fn(struct timer_list *unused)
if (!thresh)
return;

- rcu_read_lock();
-
for_each_pool(pool, pi) {
unsigned long pool_ts, touched, ts;

@@ -7587,8 +7585,6 @@ static void wq_watchdog_timer_fn(struct timer_list *unused)

}

- rcu_read_unlock();
-
if (lockup_detected)
show_all_workqueues();

--
2.17.1

\
 
 \ /
  Last update: 2025-09-04 13:34    [from the cache]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and my Meterkast|Read the blog