From: hch@lst.de (Christoph Hellwig)
Subject: [PATCH 7/8] nvme/pci: Remove volatile from cqe
Date: Wed, 27 Mar 2019 14:55:48 +0100 [thread overview]
Message-ID: <20190327135548.GE25849@lst.de> (raw)
In-Reply-To: <ad2add1c-efa6-c446-9685-6ea4ce7c2c45@grimberg.me>
On Mon, Mar 11, 2019@04:56:14PM -0700, Sagi Grimberg wrote:
>
>>> The cqe isn't volatile once we confirm the phase bit. Remove the volatile
>>> keyword and let the compiler optimize out an unnecessary additional read
>>> to the command id.
>>
>> Hmm. I've never been happy about how we used volatile to start with,
>> but I'm not sure more casts sort out this problem.
>>
>> Wouldn't the right fix be to drop the volatile entirely and force
>> a strong barrier before first reading the phase bit?
>
> Is there a fundamental difference efficiency-wise?
I'm not sure. The latter is just more our usual Linux style.
next prev parent reply other threads:[~2019-03-27 13:55 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-03-08 17:43 [PATCH 1/8] nvme/pci: Use a flag for polled queues Keith Busch
2019-03-08 17:43 ` [PATCH 2/8] nvme/pci: Don't poll polled queues in timeout Keith Busch
2019-03-11 18:25 ` Christoph Hellwig
2019-03-11 23:33 ` Sagi Grimberg
2019-03-08 17:43 ` [PATCH 3/8] nvme/pci: Remove tag check in nvme_process_cq Keith Busch
2019-03-11 18:26 ` Christoph Hellwig
2019-03-11 23:35 ` Sagi Grimberg
2019-03-08 17:43 ` [PATCH 4/8] nvme/pci: Remove last_cq_seen Keith Busch
2019-03-11 18:28 ` Christoph Hellwig
2019-03-11 23:40 ` Sagi Grimberg
2019-03-27 13:55 ` Christoph Hellwig
2019-03-08 17:43 ` [PATCH 5/8] nvme/pci: Remove last_sq_tail Keith Busch
2019-03-11 18:31 ` Christoph Hellwig
2019-03-11 19:21 ` Keith Busch
2019-03-11 23:53 ` Sagi Grimberg
2019-03-08 17:43 ` [PATCH 6/8] nvme/pci: Remove q_dmadev from nvme_queue Keith Busch
2019-03-11 18:31 ` Christoph Hellwig
2019-03-11 23:54 ` Sagi Grimberg
2019-03-27 13:53 ` Christoph Hellwig
2019-03-08 17:43 ` [PATCH 7/8] nvme/pci: Remove volatile from cqe Keith Busch
2019-03-11 18:33 ` Christoph Hellwig
2019-03-11 23:56 ` Sagi Grimberg
2019-03-27 13:55 ` Christoph Hellwig [this message]
2019-03-08 17:43 ` [PATCH 8/8] nvme/pci: Remove unused nvme_iod member Keith Busch
2019-03-11 18:33 ` Christoph Hellwig
2019-03-11 23:56 ` Sagi Grimberg
2019-03-27 13:53 ` Christoph Hellwig
2019-03-11 18:25 ` [PATCH 1/8] nvme/pci: Use a flag for polled queues Christoph Hellwig
2019-03-11 23:31 ` Sagi Grimberg
2019-03-27 13:53 ` Christoph Hellwig
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=20190327135548.GE25849@lst.de \
--to=hch@lst.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;
as well as URLs for NNTP newsgroup(s).