summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/io_uring_enter.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/test/io_uring_enter.c b/test/io_uring_enter.c
index d6e407e..b25afd5 100644
--- a/test/io_uring_enter.c
+++ b/test/io_uring_enter.c
@@ -262,9 +262,11 @@ main(int argc, char **argv)
ktail = *sq->ktail;
sq->array[ktail & mask] = index;
++ktail;
- write_barrier();
- *sq->ktail = ktail;
- write_barrier();
+ /*
+ * Ensure that the kernel sees the SQE update before it sees the tail
+ * update.
+ */
+ smp_store_release(sq->ktail, ktail);
ret = io_uring_enter(ring.ring_fd, 1, 0, 0, NULL);
/* now check to see if our sqe was dropped */