From: Pavel Begunkov <[email protected]>
To: [email protected]
Cc: Jens Axboe <[email protected]>, [email protected]
Subject: [PATCH liburing 1/6] test/zc: improve error messages
Date: Thu, 4 Aug 2022 15:20:20 +0100 [thread overview]
Message-ID: <094a2939de904ea81e65277e10662a1db6e2a068.1659622771.git.asml.silence@gmail.com> (raw)
In-Reply-To: <[email protected]>
Signed-off-by: Pavel Begunkov <[email protected]>
---
test/send-zerocopy.c | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/test/send-zerocopy.c b/test/send-zerocopy.c
index 6fa0535..c04e905 100644
--- a/test/send-zerocopy.c
+++ b/test/send-zerocopy.c
@@ -676,7 +676,7 @@ static int do_test_inet_send(struct io_uring *ring, int sock_client, int sock_se
ret = io_uring_submit(ring);
if (ret != nr_reqs) {
- fprintf(stderr, "submit failed %i expected %i\n", ret, nr_reqs);
+ fprintf(stderr, "submit failed, got %i expected %i\n", ret, nr_reqs);
return 1;
}
@@ -704,14 +704,15 @@ static int do_test_inet_send(struct io_uring *ring, int sock_client, int sock_se
ret = recv(sock_server, rx_buffer, send_size, 0);
if (ret != send_size) {
- fprintf(stderr, "recv less than expected or recv failed %i\n", ret);
+ fprintf(stderr, "recv less than expected or recv failed, "
+ "got %i, errno %i\n", ret, errno);
return 1;
}
for (i = 0; i < send_size; i++) {
if (buf[i] != rx_buffer[i]) {
- fprintf(stderr, "botched data, first byte %i, %u vs %u\n",
- i, buf[i], rx_buffer[i]);
+ fprintf(stderr, "botched data, first mismated byte %i, "
+ "%u vs %u\n", i, buf[i], rx_buffer[i]);
}
}
return 0;
--
2.37.0
next prev parent reply other threads:[~2022-08-04 14:21 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-08-04 14:20 [PATCH liburing 0/6] improve zeoropy testing Pavel Begunkov
2022-08-04 14:20 ` Pavel Begunkov [this message]
2022-08-04 14:20 ` [PATCH liburing 2/6] tests/zc: test tcp Pavel Begunkov
2022-08-04 14:20 ` [PATCH liburing 3/6] test/zc: allocate buffers dynamically Pavel Begunkov
2022-08-04 14:20 ` [PATCH liburing 4/6] test/zc: handle short rx Pavel Begunkov
2022-08-04 14:20 ` [PATCH liburing 5/6] test/zc: recv asynchronously Pavel Begunkov
2022-08-04 14:20 ` [PATCH liburing 6/6] test/zc: test short zc send Pavel Begunkov
2022-08-04 22:22 ` [PATCH liburing 0/6] improve zeoropy testing 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=094a2939de904ea81e65277e10662a1db6e2a068.1659622771.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