public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Peter Zijlstra <peterz@infradead.org>
To: "T.Zhou" <t1zhou@163.com>
Cc: mingo@redhat.com, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] sched: Assign !p->on_cpu to the second parameter of smp_cond_load_acquire()
Date: Fri, 1 Jul 2016 08:55:42 +0200	[thread overview]
Message-ID: <20160701065542.GJ30921@twins.programming.kicks-ass.net> (raw)
In-Reply-To: <20160701030801.GA15593@root>

On Fri, Jul 01, 2016 at 11:08:01AM +0800, T.Zhou wrote:

> -	smp_cond_load_acquire(&p->on_cpu, !VAL);
> +	smp_cond_load_acquire(&p->on_cpu, !p->on_cpu);

Huh, what?! No, the second parameter should very much include VAL, which
gets assigned the value of *(&p->on_cpu).

Go read the macro, it even has a comment on.

      reply	other threads:[~2016-07-01  8:40 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-07-01  3:08 [PATCH] sched: Assign !p->on_cpu to the second parameter of smp_cond_load_acquire() T.Zhou
2016-07-01  6:55 ` Peter Zijlstra [this message]

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=20160701065542.GJ30921@twins.programming.kicks-ass.net \
    --to=peterz@infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=t1zhou@163.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox