Re: [PATCH 03/10] ptrace: implement PTRACE_SEIZE

From: Tejun Heo
Date: Wed May 18 2011 - 07:14:33 EST


Hello, Denys.

On Wed, May 18, 2011 at 12:44:58PM +0200, Denys Vlasenko wrote:
> > But as SEIZE introduces behavior differences throughout ptrace
> > operation,
> >
> > Similar issue with PTRACE_O_TRACESTOP. It won't only enable TRACESTOP
> > it will change other behaviors too
>
> All these differences revolve around making handling of stops
> and SIGCONT better. It seems fitting to the option name.
>
> PTRACE_SEIZE sets a flag somewhere "please convert
> group-stops into PTRACE_EVENT_STOPs".

I don't know. It seems a bit too subtle. The new behaviors are a lot
more pervasive than any controlled by PTRACE_O_ flags and there's the
problem of allowing its clearing.

> Since we have this API, why not use it for the very similar
> concept of modifying group-stops too?

Different scope. Conflicting semantics (clearing). API compatibility
as you pointed out.

> > I think it's actually beneficial to use a distinctively new
> > request. It's not like it costs anything or we're short on request
> > number space.
>
> "Entities must not be multiplied beyond necessity"?

Sure, but whether to have a flag or a request is trivial. When one of
them has issues like above, I see a new request number go above the
necessity threshold.

Thanks.

--
tejun
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/