[PATCH 6/9] signal: Always call do_notify_parent_cldstop with siglock held
Oleg Nesterov
oleg at redhat.com
Thu Apr 28 11:22:58 PDT 2022
On 04/28, Peter Zijlstra wrote:
>
> I've not had time to fully appreciate the nested locking here, but if it
> is possible to rework things to always take both locks at the same time,
> then it would be possible to impose an arbitrary lock order on things
> and break the cycle that way.
This is clear, but this is not that simple.
For example (with this series at least), ptrace_stop() already holds
current->sighand->siglock which (in particular) we need to protect
current->parent, but then we need current->parent->sighand->siglock
in do_notify_parent_cldstop().
Oleg.
More information about the linux-um
mailing list