]> git.baikalelectronics.ru Git - kernel.git/commit
io_uring: fix notes on barriers
authorStefan Bühler <source@stbuehler.de>
Wed, 24 Apr 2019 21:54:16 +0000 (23:54 +0200)
committerJens Axboe <axboe@kernel.dk>
Tue, 30 Apr 2019 15:40:02 +0000 (09:40 -0600)
commit683d2859c9f1cd5781dce5c5828ae44eba70b943
tree8db2e33c5aabfc341a9b1b5a6d17297747ba67f0
parent33bb9f0f1c50195fb1f0edef24bf6ee778584e2e
io_uring: fix notes on barriers

The application reading the CQ ring needs a barrier to pair with the
smp_store_release in io_commit_cqring, not the barrier after it.

Also a write barrier *after* writing something (but not *before*
writing anything interesting) doesn't order anything, so an smp_wmb()
after writing SQ tail is not needed.

Additionally consider reading SQ head and writing CQ tail in the notes.

Also add some clarifications how the various other fields in the ring
buffers are used.

Signed-off-by: Stefan Bühler <source@stbuehler.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
fs/io_uring.c