From: Joe Perches <joe@perches.com>
To: paulmck@linux.ibm.com, Andrea Parri <andrea.parri@amarulasolutions.com>
Cc: linux-kernel@vger.kernel.org,
Josh Triplett <josh@joshtriplett.org>,
Steven Rostedt <rostedt@goodmis.org>,
Mathieu Desnoyers <mathieu.desnoyers@efficios.com>,
Lai Jiangshan <jiangshanlai@gmail.com>,
Joel Fernandes <joel@joelfernandes.org>,
rcu@vger.kernel.org, Peter Zijlstra <peterz@infradead.org>,
Will Deacon <will.deacon@arm.com>,
Mark Rutland <mark.rutland@arm.com>,
Matthew Wilcox <willy@infradead.org>,
Sasha Levin <sashal@kernel.org>,
apw@canonical.com
Subject: Re: [PATCH v2] rcu: Don't return a value from rcu_assign_pointer()
Date: Mon, 27 May 2019 10:21:22 -0700 [thread overview]
Message-ID: <810a0dae47c90c39015903c413303fcee89ab5eb.camel@perches.com> (raw)
In-Reply-To: <20190527161050.GK28207@linux.ibm.com>
On Mon, 2019-05-27 at 09:10 -0700, Paul E. McKenney wrote:
> On Mon, May 27, 2019 at 10:49:57AM +0200, Andrea Parri wrote:
> > Quoting Paul [1]:
> >
> > "Given that a quick (and perhaps error-prone) search of the uses
> > of rcu_assign_pointer() in v5.1 didn't find a single use of the
> > return value, let's please instead change the documentation and
> > implementation to eliminate the return value."
> >
> > [1] https://lkml.kernel.org/r/20190523135013.GL28207@linux.ibm.com
>
> Queued, thank you!
>
> Adding the checkpatch maintainers on CC as well. The "do { } while
> (0)" prevents the return value from being used, by design. Given the
> checkpatch complaint, is there some better way to achieve this?
Not sure what the checkpatch complaint is here.
Reading the link above, there seems to be a compiler warning.
Perhaps a statement expression macro with no return value?
#define rcu_assign_pointer(p, v) ({ (p) = (v); ; })
next prev parent reply other threads:[~2019-05-27 17:21 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-05-27 8:49 Andrea Parri
2019-05-27 16:10 ` Paul E. McKenney
2019-05-27 17:21 ` Joe Perches [this message]
2019-05-27 17:49 ` Paul E. McKenney
2019-05-27 17:57 ` Joe Perches
2019-05-27 19:23 ` Paul E. McKenney
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=810a0dae47c90c39015903c413303fcee89ab5eb.camel@perches.com \
--to=joe@perches.com \
--cc=andrea.parri@amarulasolutions.com \
--cc=apw@canonical.com \
--cc=jiangshanlai@gmail.com \
--cc=joel@joelfernandes.org \
--cc=josh@joshtriplett.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mark.rutland@arm.com \
--cc=mathieu.desnoyers@efficios.com \
--cc=paulmck@linux.ibm.com \
--cc=peterz@infradead.org \
--cc=rcu@vger.kernel.org \
--cc=rostedt@goodmis.org \
--cc=sashal@kernel.org \
--cc=will.deacon@arm.com \
--cc=willy@infradead.org \
/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
all inboxes | Powered by JetHome®