public inbox for [email protected]
 help / color / mirror / Atom feed
From: Pavel Begunkov <[email protected]>
To: [email protected]
Cc: Jens Axboe <[email protected]>, [email protected]
Subject: [PATCH liburing for-next 5/5] tests: test poll_first
Date: Thu, 20 Oct 2022 02:49:55 +0100	[thread overview]
Message-ID: <ea489a5ada8b5ef24e039715713f325541267ca0.1666230529.git.asml.silence@gmail.com> (raw)
In-Reply-To: <[email protected]>

Signed-off-by: Pavel Begunkov <[email protected]>
---
 test/send-zerocopy.c | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/test/send-zerocopy.c b/test/send-zerocopy.c
index 010bf50..1403fd5 100644
--- a/test/send-zerocopy.c
+++ b/test/send-zerocopy.c
@@ -265,6 +265,7 @@ struct send_conf {
 	bool zc;
 	bool iovec;
 	bool long_iovec;
+	bool poll_first;
 	int buf_index;
 	struct sockaddr_storage *addr;
 };
@@ -375,6 +376,8 @@ static int do_test_inet_send(struct io_uring *ring, int sock_client, int sock_se
 		sqe->user_data = i;
 		if (conf->force_async)
 			sqe->flags |= IOSQE_ASYNC;
+		if (conf->poll_first)
+			sqe->ioprio |= IORING_RECVSEND_POLL_FIRST;
 		if (i != nr_reqs - 1)
 			sqe->flags |= IOSQE_IO_LINK;
 	}
@@ -463,7 +466,7 @@ static int test_inet_send(struct io_uring *ring)
 			return 1;
 		}
 
-		for (i = 0; i < 2048; i++) {
+		for (i = 0; i < 4096; i++) {
 			bool regbuf;
 
 			conf.buf_index = i & 3;
@@ -476,6 +479,7 @@ static int test_inet_send(struct io_uring *ring)
 			conf.zc = i & 256;
 			conf.iovec = i & 512;
 			conf.long_iovec = i & 1024;
+			conf.poll_first = i & 2048;
 			conf.tcp = tcp;
 			regbuf = conf.mix_register || conf.fixed_buf;
 
-- 
2.38.0


  parent reply	other threads:[~2022-10-20  1:51 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-10-20  1:49 [PATCH liburing for-next 0/5] expand send / zc tests Pavel Begunkov
2022-10-20  1:49 ` [PATCH liburing for-next 1/5] tests: improve zc cflags handling Pavel Begunkov
2022-10-20  1:49 ` [PATCH liburing for-next 2/5] tests: pass params in a struct Pavel Begunkov
2022-10-20  1:49 ` [PATCH liburing for-next 3/5] tests: add non-zc tests in send-zerocopy.c Pavel Begunkov
2022-10-20  1:49 ` [PATCH liburing for-next 4/5] tests: add tests for retries with long iovec Pavel Begunkov
2022-10-20  1:49 ` Pavel Begunkov [this message]
2022-10-20  2:26 ` [PATCH liburing for-next 0/5] expand send / zc tests Jens Axboe

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ea489a5ada8b5ef24e039715713f325541267ca0.1666230529.git.asml.silence@gmail.com \
    [email protected] \
    [email protected] \
    [email protected] \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox