Merge tag 'io_uring-6.11-20240824' of git://git.kernel.dk/linux
Pull io_uring fixes from Jens Axboe: - Fix a comment in the uapi header using the wrong member name (Caleb) - Fix KCSAN warning for a debug check in sqpoll (me) - Two more NAPI tweaks (Olivier) * tag 'io_uring-6.11-20240824' of git://git.kernel.dk/linux: io_uring: fix user_data field name in comment io_uring/sqpoll: annotate debug task == current with data_race() io_uring/napi: remove duplicate io_napi_entry timeout assignation io_uring/napi: check napi_enabled in io_napi_add() before proceeding
This commit is contained in:
@@ -421,7 +421,7 @@ enum io_uring_msg_ring_flags {
|
||||
* IO completion data structure (Completion Queue Entry)
|
||||
*/
|
||||
struct io_uring_cqe {
|
||||
__u64 user_data; /* sqe->data submission passed back */
|
||||
__u64 user_data; /* sqe->user_data value passed back */
|
||||
__s32 res; /* result code for this event */
|
||||
__u32 flags;
|
||||
|
||||
|
||||
+1
-2
@@ -26,7 +26,6 @@ static struct io_napi_entry *io_napi_hash_find(struct hlist_head *hash_list,
|
||||
hlist_for_each_entry_rcu(e, hash_list, node) {
|
||||
if (e->napi_id != napi_id)
|
||||
continue;
|
||||
e->timeout = jiffies + NAPI_TIMEOUT;
|
||||
return e;
|
||||
}
|
||||
|
||||
@@ -302,7 +301,7 @@ void __io_napi_busy_loop(struct io_ring_ctx *ctx, struct io_wait_queue *iowq)
|
||||
{
|
||||
iowq->napi_prefer_busy_poll = READ_ONCE(ctx->napi_prefer_busy_poll);
|
||||
|
||||
if (!(ctx->flags & IORING_SETUP_SQPOLL) && ctx->napi_enabled)
|
||||
if (!(ctx->flags & IORING_SETUP_SQPOLL))
|
||||
io_napi_blocking_busy_loop(ctx, iowq);
|
||||
}
|
||||
|
||||
|
||||
+1
-1
@@ -55,7 +55,7 @@ static inline void io_napi_add(struct io_kiocb *req)
|
||||
struct io_ring_ctx *ctx = req->ctx;
|
||||
struct socket *sock;
|
||||
|
||||
if (!READ_ONCE(ctx->napi_busy_poll_dt))
|
||||
if (!READ_ONCE(ctx->napi_enabled))
|
||||
return;
|
||||
|
||||
sock = sock_from_file(req->file);
|
||||
|
||||
+1
-1
@@ -44,7 +44,7 @@ void io_sq_thread_unpark(struct io_sq_data *sqd)
|
||||
void io_sq_thread_park(struct io_sq_data *sqd)
|
||||
__acquires(&sqd->lock)
|
||||
{
|
||||
WARN_ON_ONCE(sqd->thread == current);
|
||||
WARN_ON_ONCE(data_race(sqd->thread) == current);
|
||||
|
||||
atomic_inc(&sqd->park_pending);
|
||||
set_bit(IO_SQ_THREAD_SHOULD_PARK, &sqd->state);
|
||||
|
||||
Reference in New Issue
Block a user