Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

io_uring/register: drop io_register_enable_rings() submitter_task check

io_register_enable_rings() checks that the io_ring_ctx is
IORING_SETUP_R_DISABLED, which ensures submitter_task hasn't been
assigned by io_uring_create() or a previous io_register_enable_rings()
call. So drop the redundant check that submitter_task is NULL.

Signed-off-by: Caleb Sander Mateos <csander@purestorage.com>
Reviewed-by: Joanne Koong <joannelkoong@gmail.com>
Reviewed-by: Gabriel Krisman Bertazi <krisman@suse.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>

authored by

Caleb Sander Mateos and committed by
Jens Axboe
130a8276 bcd4c957

+1 -1
+1 -1
io_uring/register.c
··· 180 180 if (!(ctx->flags & IORING_SETUP_R_DISABLED)) 181 181 return -EBADFD; 182 182 183 - if (ctx->flags & IORING_SETUP_SINGLE_ISSUER && !ctx->submitter_task) { 183 + if (ctx->flags & IORING_SETUP_SINGLE_ISSUER) { 184 184 ctx->submitter_task = get_task_struct(current); 185 185 /* 186 186 * Lazy activation attempts would fail if it was polled before