All of lore.kernel.org
 help / color / mirror / Atom feed
From: Peter Zijlstra <peterz@infradead.org>
To: Oleg Nesterov <oleg@redhat.com>
Cc: Sven Schnelle <svens@linux.ibm.com>,
	Steven Rostedt <rostedt@goodmis.org>,
	Alexander Gordeev <agordeev@linux.ibm.com>,
	"Eric W. Biederman" <ebiederm@xmission.com>,
	Kees Cook <keescook@chromium.org>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] ptrace: fix clearing of JOBCTL_TRACED in ptrace_unfreeze_traced()
Date: Wed, 6 Jul 2022 13:13:46 +0200	[thread overview]
Message-ID: <YsVuak0/upU2Rvm6@worktop.programming.kicks-ass.net> (raw)
In-Reply-To: <20220706110438.GB9868@redhat.com>

On Wed, Jul 06, 2022 at 01:04:38PM +0200, Oleg Nesterov wrote:
> On 07/06, Sven Schnelle wrote:
> >
> > --- a/kernel/ptrace.c
> > +++ b/kernel/ptrace.c
> > @@ -222,7 +222,7 @@ static void ptrace_unfreeze_traced(struct task_struct *task)
> >  	if (lock_task_sighand(task, &flags)) {
> >  		task->jobctl &= ~JOBCTL_PTRACE_FROZEN;
> >  		if (__fatal_signal_pending(task)) {
> > -			task->jobctl &= ~TASK_TRACED;
> > +			task->jobctl &= ~JOBCTL_TRACED;
> 
> Heh. I have read this code many times, but I'm afraid I could read it
> 1000 times more and didn't notice the problem ;)

Heh, same here, I've read it today and didn't spot the problem. Brains
are weird.

  reply	other threads:[~2022-07-06 11:14 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-06 10:16 [PATCH] ptrace: fix clearing of JOBCTL_TRACED in ptrace_unfreeze_traced() Sven Schnelle
2022-07-06 10:44 ` Peter Zijlstra
2022-07-06 11:04 ` Oleg Nesterov
2022-07-06 11:13   ` Peter Zijlstra [this message]
2022-07-06 12:48 ` Alexander Gordeev
2022-07-06 21:15 ` Eric W. Biederman

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=YsVuak0/upU2Rvm6@worktop.programming.kicks-ass.net \
    --to=peterz@infradead.org \
    --cc=agordeev@linux.ibm.com \
    --cc=ebiederm@xmission.com \
    --cc=keescook@chromium.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=oleg@redhat.com \
    --cc=rostedt@goodmis.org \
    --cc=svens@linux.ibm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.