diff options
author | Matthias Kaehlcke <matthias.kaehlcke@gmail.com> | 2007-10-15 11:00:02 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2007-10-15 11:00:02 -0400 |
commit | 2e45874c5aabe573b6ab4328f303c765701394f9 (patch) | |
tree | a779cec221d8f1601f105ad5cf48f8ae4a2a42e8 /kernel | |
parent | bb61c210835db95b0e9fb612a316422e7cc675e3 (diff) |
sched: use list_for_each_entry_safe() in __wake_up_common()
Use list_for_each_entry_safe() instead of list_for_each_safe() in
__wake_up_common()
Signed-off-by: Matthias Kaehlcke <matthias.kaehlcke@gmail.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Signed-off-by: Mike Galbraith <efault@gmx.de>
Reviewed-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'kernel')
-rw-r--r-- | kernel/sched.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/kernel/sched.c b/kernel/sched.c index 2054e557d0d2..e92b185e371b 100644 --- a/kernel/sched.c +++ b/kernel/sched.c | |||
@@ -3634,10 +3634,9 @@ EXPORT_SYMBOL(default_wake_function); | |||
3634 | static void __wake_up_common(wait_queue_head_t *q, unsigned int mode, | 3634 | static void __wake_up_common(wait_queue_head_t *q, unsigned int mode, |
3635 | int nr_exclusive, int sync, void *key) | 3635 | int nr_exclusive, int sync, void *key) |
3636 | { | 3636 | { |
3637 | struct list_head *tmp, *next; | 3637 | wait_queue_t *curr, *next; |
3638 | 3638 | ||
3639 | list_for_each_safe(tmp, next, &q->task_list) { | 3639 | list_for_each_entry_safe(curr, next, &q->task_list, task_list) { |
3640 | wait_queue_t *curr = list_entry(tmp, wait_queue_t, task_list); | ||
3641 | unsigned flags = curr->flags; | 3640 | unsigned flags = curr->flags; |
3642 | 3641 | ||
3643 | if (curr->func(curr, mode, sync, key) && | 3642 | if (curr->func(curr, mode, sync, key) && |