[RFC] io_uring: submit even with overflow backlog

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Not submitting when have requests in overflow backlog looks artificial,
and limits users for no clear purpose, especially since requests with
resources are now not locked into it but it consists for a small memory
area. Remove the restriction.

Signed-off-by: Pavel Begunkov <asml.silence@xxxxxxxxx>
---

Mainly for discussion. It breaks several tests, and so in theory
userspace, but can't think this restriction not being just a
nuisance to the userspace. IMHO much more convenient to allow it,
userspace can take care of it itself if needed, but for those
who don't care and use rings in parallel (e.g. different threads
for submission and completion), it will be hell of a synchronisation.

 fs/io_uring.c | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/fs/io_uring.c b/fs/io_uring.c
index 357993e3e0d2..21026653e1c1 100644
--- a/fs/io_uring.c
+++ b/fs/io_uring.c
@@ -6673,12 +6673,6 @@ static int io_submit_sqes(struct io_ring_ctx *ctx, unsigned int nr)
 {
 	int submitted = 0;
 
-	/* if we have a backlog and couldn't flush it all, return BUSY */
-	if (test_bit(0, &ctx->sq_check_overflow)) {
-		if (!__io_cqring_overflow_flush(ctx, false))
-			return -EBUSY;
-	}
-
 	/* make sure SQ entry isn't read before tail */
 	nr = min3(nr, ctx->sq_entries, io_sqring_entries(ctx));
 
-- 
2.24.0




[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux