* [PATCH] sched/wait: kill leftover bookmark logic in __wake_up_common()
@ 2026-11-12 16:55 Oleg Nesterov
0 siblings, 0 replies; only message in thread
From: Oleg Nesterov @ 2026-11-12 16:55 UTC (permalink / raw)
To: Ingo Molnar, Juri Lelli, Matthew Wilcox, Peter Zijlstra, Vincent Guittot
Cc: Andrew Morton, linux-kernel
The manual list head check and list_for_each_entry_safe_from() in
__wake_up_common() are leftovers from commit 2554db916586 ("sched/wait:
Break up long wake list walk").
This logic was later removed by commit 37acade0ce89 ("sched: remove
wait bookmarks") but the now-unnecessary list hacks were left behind.
Signed-off-by: Oleg Nesterov <oleg@redhat.com>
---
kernel/sched/wait.c | 7 +------
1 file changed, 1 insertion(+), 6 deletions(-)
diff --git a/kernel/sched/wait.c b/kernel/sched/wait.c
index f8d6d8b9d03e..d0521b54eeb3 100644
--- a/kernel/sched/wait.c
+++ b/kernel/sched/wait.c
@@ -96,12 +96,7 @@ static int __wake_up_common(struct wait_queue_head *wq_head, unsigned int mode,
lockdep_assert_held(&wq_head->lock);
- curr = list_first_entry(&wq_head->head, wait_queue_entry_t, entry);
-
- if (&curr->entry == &wq_head->head)
- return nr_exclusive;
-
- list_for_each_entry_safe_from(curr, next, &wq_head->head, entry) {
+ list_for_each_entry_safe(curr, next, &wq_head->head, entry) {
unsigned flags = curr->flags;
int ret;
--
2.55.0
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2026-11-12 16:55 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-11-12 16:55 [PATCH] sched/wait: kill leftover bookmark logic in __wake_up_common() Oleg Nesterov
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®