From: Jeff Layton <jlayton@kernel.org>
To: NeilBrown <neilb@suse.de>, Chuck Lever <chuck.lever@oracle.com>
Cc: linux-nfs@vger.kernel.org,
Olga Kornievskaia <okorniev@redhat.com>,
Dai Ngo <Dai.Ngo@oracle.com>, Tom Talpey <tom@talpey.com>
Subject: Re: [PATCH 2/2] sunrpc/svc: use store_release_wake_up()
Date: Thu, 05 Dec 2024 21:41:33 -0800 [thread overview]
Message-ID: <216ae53f9ab71f9e081bf5d9e6fdcbe30d1dbd3d.camel@kernel.org> (raw)
In-Reply-To: <20241206025723.3537777-3-neilb@suse.de>
On Fri, 2024-12-06 at 13:55 +1100, NeilBrown wrote:
> svc_thread_init_status() contains an open-coded
> store_release_wake_up(). It is cleaner to use that function directly
> rather than needing to remember the barrier.
>
> Signed-off-by: NeilBrown <neilb@suse.de>
> ---
> include/linux/sunrpc/svc.h | 7 +------
> 1 file changed, 1 insertion(+), 6 deletions(-)
>
> diff --git a/include/linux/sunrpc/svc.h b/include/linux/sunrpc/svc.h
> index e68fecf6eab5..e4f09f58d58c 100644
> --- a/include/linux/sunrpc/svc.h
> +++ b/include/linux/sunrpc/svc.h
> @@ -327,12 +327,7 @@ static inline bool svc_thread_should_stop(struct svc_rqst *rqstp)
> */
> static inline void svc_thread_init_status(struct svc_rqst *rqstp, int err)
> {
> - rqstp->rq_err = err;
> - /* memory barrier ensures assignment to error above is visible before
> - * waitqueue_active() test below completes.
> - */
> - smp_mb();
> - wake_up_var(&rqstp->rq_err);
> + store_release_wake_up(&rqstp->rq_err, err);
> if (err)
> kthread_exit(1);
> }
Reviewed-by: Jeff Layton <jlayton@kernel.org>
next prev parent reply other threads:[~2024-12-06 5:41 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-12-06 2:55 [PATCH 0/2] nfsd: use new wake_up_var interface NeilBrown
2024-12-06 2:55 ` [PATCH 1/2] nfsd: use new wake_up_var interfaces NeilBrown
2024-12-06 5:40 ` Jeff Layton
2024-12-06 6:10 ` NeilBrown
2024-12-06 15:27 ` Jeff Layton
2024-12-06 2:55 ` [PATCH 2/2] sunrpc/svc: use store_release_wake_up() NeilBrown
2024-12-06 5:41 ` Jeff Layton [this message]
2024-12-06 21:56 ` [PATCH 0/2] nfsd: use new wake_up_var interface cel
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=216ae53f9ab71f9e081bf5d9e6fdcbe30d1dbd3d.camel@kernel.org \
--to=jlayton@kernel.org \
--cc=Dai.Ngo@oracle.com \
--cc=chuck.lever@oracle.com \
--cc=linux-nfs@vger.kernel.org \
--cc=neilb@suse.de \
--cc=okorniev@redhat.com \
--cc=tom@talpey.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