MCPcopy Create free account
hub / github.com/axboe/liburing / try_io_uring_enter

Function try_io_uring_enter

test/io_uring_enter.c:55–72  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

53}
54
55static int try_io_uring_enter(int fd, unsigned int to_submit,
56 unsigned int min_complete, unsigned int flags,
57 sigset_t *sig, int expect)
58{
59 int ret;
60
61 if (expect < 0)
62 return expect_fail(fd, to_submit, min_complete, flags, sig,
63 expect);
64
65 ret = io_uring_enter(fd, to_submit, min_complete, flags, sig);
66 if (ret != expect) {
67 fprintf(stderr, "Expected %d, got %d\n", expect, ret);
68 return 1;
69 }
70
71 return 0;
72}
73
74/*
75 * prep a read I/O. index is treated like a block number.

Callers 1

mainFunction · 0.85

Calls 2

io_uring_enterFunction · 0.85
expect_failFunction · 0.70

Tested by

no test coverage detected