Re: [PATCH v3 1/4] ptrace: move clearing of TIF_SYSCALL_EMU flag to core

From: Oleg Nesterov
Date: Wed May 01 2019 - 12:13:53 EST


On 04/30, Sudeep Holla wrote:
>
> While the TIF_SYSCALL_EMU is set in ptrace_resume independent of any
> architecture, currently only powerpc and x86 unset the TIF_SYSCALL_EMU
> flag in ptrace_disable which gets called from ptrace_detach.
>
> Let's move the clearing of TIF_SYSCALL_EMU flag to __ptrace_unlink
> which gets executed from ptrace_detach and also keep it along with
> or close to clearing of TIF_SYSCALL_TRACE.
>
> Cc: Oleg Nesterov <oleg@xxxxxxxxxx>
> Cc: Paul Mackerras <paulus@xxxxxxxxx>
> Cc: Michael Ellerman <mpe@xxxxxxxxxxxxxx>
> Cc: Thomas Gleixner <tglx@xxxxxxxxxxxxx>
> Cc: Ingo Molnar <mingo@xxxxxxxxxx>
> Signed-off-by: Sudeep Holla <sudeep.holla@xxxxxxx>

Acked-by: Oleg Nesterov <oleg@xxxxxxxxxx>