aboutsummaryrefslogtreecommitdiffstats
path: root/kernel
diff options
context:
space:
mode:
authorMandeep Singh Baines <msb@google.com>2009-02-05 12:56:08 -0500
committerIngo Molnar <mingo@elte.hu>2009-02-05 13:55:31 -0500
commit94be52dc075a32af4aa73d7e10f68734d62d6af2 (patch)
tree70e4f2bf93dda15a27b79baf49bbfd3fc5982ba1 /kernel
parentce9dbe244bf2063c41792e40dae7745957b118e0 (diff)
softlockup: convert read_lock in hung_task to rcu_read_lock
Since the tasklist is protected by rcu list operations, it is safe to convert the read_lock()s to rcu_read_lock(). Suggested-by: Peter Zijlstra <a.p.zijlstra@chello.nl> Signed-off-by: Mandeep Singh Baines <msb@google.com> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'kernel')
-rw-r--r--kernel/hung_task.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/kernel/hung_task.c b/kernel/hung_task.c
index 481ca8b5c2bc..3951a80e7cbe 100644
--- a/kernel/hung_task.c
+++ b/kernel/hung_task.c
@@ -155,7 +155,7 @@ static void check_hung_uninterruptible_tasks(unsigned long timeout)
155 if (test_taint(TAINT_DIE) || did_panic) 155 if (test_taint(TAINT_DIE) || did_panic)
156 return; 156 return;
157 157
158 read_lock(&tasklist_lock); 158 rcu_read_lock();
159 do_each_thread(g, t) { 159 do_each_thread(g, t) {
160 if (!--max_count) 160 if (!--max_count)
161 goto unlock; 161 goto unlock;
@@ -171,7 +171,7 @@ static void check_hung_uninterruptible_tasks(unsigned long timeout)
171 check_hung_task(t, now, timeout); 171 check_hung_task(t, now, timeout);
172 } while_each_thread(g, t); 172 } while_each_thread(g, t);
173 unlock: 173 unlock:
174 read_unlock(&tasklist_lock); 174 rcu_read_unlock();
175} 175}
176 176
177static void update_poll_jiffies(void) 177static void update_poll_jiffies(void)