Rename SIG_IS_DATA -> EXT_ARG
This is the final name. While doing this change, also change it so that
we only call the new variant if 'ts' is indeed set.
Signed-off-by: Jens Axboe <axboe@kernel.dk>
diff --git a/src/include/liburing/io_uring.h b/src/include/liburing/io_uring.h
index 6a74ae8..e52ad2d 100644
--- a/src/include/liburing/io_uring.h
+++ b/src/include/liburing/io_uring.h
@@ -235,7 +235,7 @@
#define IORING_ENTER_GETEVENTS (1U << 0)
#define IORING_ENTER_SQ_WAKEUP (1U << 1)
#define IORING_ENTER_SQ_WAIT (1U << 2)
-#define IORING_ENTER_SIG_IS_DATA (1U << 3)
+#define IORING_ENTER_EXT_ARG (1U << 3)
/*
* Passed in for io_uring_setup(2). Copied back with updated info on success
@@ -264,7 +264,7 @@
#define IORING_FEAT_FAST_POLL (1U << 5)
#define IORING_FEAT_POLL_32BITS (1U << 6)
#define IORING_FEAT_SQPOLL_NONFIXED (1U << 7)
-#define IORING_FEAT_SIG_IS_DATA (1U << 8)
+#define IORING_FEAT_EXT_ARG (1U << 8)
/*
* io_uring_register(2) opcodes and arguments
diff --git a/src/queue.c b/src/queue.c
index 5f46395..53ca588 100644
--- a/src/queue.c
+++ b/src/queue.c
@@ -217,8 +217,8 @@
}
/*
- * If we have kernel support for IORING_ENTERSIG_IS_DATA, then we can
- * use that more efficiently than queueing an internal timeout command.
+ * If we have kernel support for IORING_ENTER_EXT_ARG, then we can use that
+ * more efficiently than queueing an internal timeout command.
*/
static int io_uring_wait_cqes_new(struct io_uring *ring,
struct io_uring_cqe **cqe_ptr,
@@ -233,7 +233,7 @@
struct get_data data = {
.submit = __io_uring_flush_sq(ring),
.wait_nr = wait_nr,
- .get_flags = ts ? IORING_ENTER_SIG_IS_DATA : 0,
+ .get_flags = IORING_ENTER_EXT_ARG,
.sz = sizeof(arg),
.arg = &arg
};
@@ -258,13 +258,14 @@
{
unsigned to_submit = 0;
- if (ring->features & IORING_FEAT_SIG_IS_DATA)
- return io_uring_wait_cqes_new(ring, cqe_ptr, wait_nr, ts, sigmask);
-
if (ts) {
struct io_uring_sqe *sqe;
int ret;
+ if (ring->features & IORING_FEAT_EXT_ARG)
+ return io_uring_wait_cqes_new(ring, cqe_ptr, wait_nr,
+ ts, sigmask);
+
/*
* If the SQ ring is full, we may need to submit IO first
*/