From: Davidlohr Bueso <dave@stgolabs.net>
To: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Cc: linux-kernel@vger.kernel.org, George Spelvin <linux@horizon.com>,
Thomas Gleixner <tglx@linutronix.de>,
Peter Zijlstra <peterz@infradead.org>,
Manfred Spraul <manfred@colorfullife.com>,
Andrew Morton <akpm@linux-foundation.org>
Subject: Re: [PATCH v2] ipc/msg: Implement lockless pipelined wakeups
Date: Wed, 4 Nov 2015 10:11:40 -0800 [thread overview]
Message-ID: <20151104181140.GB15994@linux-uzut.site> (raw)
In-Reply-To: <56391547.2040105@linutronix.de>
On Tue, 03 Nov 2015, Sebastian Andrzej Siewior wrote:
>In pipelined_receive() (mqueue) there is the wake_q_add() with the
>implicit cmpxchg barrier. The matching barrier pairing should be in
>wq_sleep() but there is none. Why is it okay to have none there and I
>need one here?
So the pairing in mqueue is done in wq_sleep() as we unlock info->lock,
so there's an implied barrier there.
Also, considering Peter's suggestion to wrap around READ/WRITE_ONCE
for sysv queues (specially since you got rid of the volatile tag),
it seems we also need them for mqueues.
Thanks,
Davidlohr
next prev parent reply other threads:[~2015-11-04 18:11 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-11-03 15:03 Sebastian Andrzej Siewior
2015-11-03 17:30 ` Davidlohr Bueso
2015-11-03 20:12 ` Sebastian Andrzej Siewior
2015-11-04 18:11 ` Davidlohr Bueso [this message]
2015-11-04 11:55 ` Peter Zijlstra
2015-11-04 17:32 ` Davidlohr Bueso
2015-11-04 12:02 ` Peter Zijlstra
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=20151104181140.GB15994@linux-uzut.site \
--to=dave@stgolabs.net \
--cc=akpm@linux-foundation.org \
--cc=bigeasy@linutronix.de \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@horizon.com \
--cc=manfred@colorfullife.com \
--cc=peterz@infradead.org \
--cc=tglx@linutronix.de \
/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®