mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] futex: Handle the correct robust list at compat_exit_robust_list()
@ 2026-09-22  0:54 André Almeida
  2026-09-29  8:22 ` Thomas Gleixner
  0 siblings, 1 reply; 3+ messages in thread
From: André Almeida @ 2026-09-22  0:54 UTC (permalink / raw)
  To: dave, tglx, dvhart, peterz, mingo, linux-kernel, kernel-dev
  Cc: André Almeida

compat_exit_robust_list(), as exit_robust_list(), should handle the robust
list from the task_struct from the function argument, not the current task
running the function.

Fixes: 2cb5251d3d64 ("futex: Provide UABI defines for robust list entry modifiers")
Signed-off-by: André Almeida <andrealmeid@igalia.com>
---
 kernel/futex/core.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/kernel/futex/core.c b/kernel/futex/core.c
index a061f54b606d..42014dcfdf0c 100644
--- a/kernel/futex/core.c
+++ b/kernel/futex/core.c
@@ -1256,7 +1256,7 @@ compat_fetch_robust_entry(compat_uptr_t *uentry, struct robust_list __user **ent
  */
 static void compat_exit_robust_list(struct task_struct *curr)
 {
-	struct compat_robust_list_head __user *head = current->futex.compat_robust_list;
+	struct compat_robust_list_head __user *head = curr->futex.compat_robust_list;
 	unsigned int limit = ROBUST_LIST_LIMIT, cur_mod, next_mod, pend_mod;
 	struct robust_list __user *entry, *next_entry, *pending;
 	compat_uptr_t uentry, next_uentry, upending;
-- 
2.55.0


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2026-09-29 13:14 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-09-22  0:54 [PATCH] futex: Handle the correct robust list at compat_exit_robust_list() André Almeida
2026-09-29  8:22 ` Thomas Gleixner
2026-09-29 13:14   ` André Almeida

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®