commit | dc9b2640f70bd988b9995b14f5a06d3809855a76 | [log] [tgz] |
---|---|---|
author | Sebastian Andrzej Siewior <bigeasy@linutronix.de> | Fri Apr 01 12:51:23 2022 +0200 |
committer | Sebastian Andrzej Siewior <bigeasy@linutronix.de> | Fri Apr 01 12:51:23 2022 +0200 |
tree | 013d0d4e80b03326f4163920609590c6b6657864 | |
parent | 50bc3ebce96400d2d198b82634d6fcb659a951d5 [diff] |
ptrace: fix ptrace vs tasklist_lock race This is an update to the patch so it looks the way it has been presented to the list: - Use also ->saved_state in task_state_match_and_set(). - Wait in wait_task_inactive() until the desired task state is in ->__state so that the task won't wake up a as part of lock resolving. Pointed out by Oleg Nesterov. Link: https://lore.kernel.org/r/YkW55u6u2fo5QmV7@linutronix.de Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>