lkml.org 
[lkml]   [2009]   [Mar]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [patch 3/14] x86, ptrace, bts: stop bts tracing early in do_exit
On 03/27, Markus Metzger wrote:
>
> +static void ptrace_bts_exit(void)
> +{
> + if (unlikely(!list_empty(&current->ptraced)))
> + ptrace_bts_exit_tracer();
> +
> + if (unlikely(current->bts))
> + ptrace_bts_exit_tracee();
> +}

Could you explain why do we need ptrace_bts_exit_tracee() ?

If current is traced, the tracer should do ptrace_bts_release()
eventually, no?

And if we really need to do ptrace_bts_exit_tracee(), then
"if (unlikely(current->bts))" check is racy. The tracer
can do PTRACE_BTS_CONFIG right after the check.

Oleg.



\
 
 \ /
  Last update: 2009-03-27 15:41    [W:0.072 / U:0.060 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site