Age | Commit message (Collapse) | Author |
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Since the liburing header files support C++ compilers, add a C++ unit test.
This helps to verify C++ compatibility of the liburing header files.
Signed-off-by: Bart Van Assche <bvanassche@acm.org>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
This triggers a bug present until at least Linux 5.6.11, causing
EBADF, see https://lkml.org/lkml/2020/5/7/1287
Signed-off-by: Max Kellermann <mk@cm4all.com>
|
|
'th doesn't really work for 1/2/3 timeouts, just use # to make it
clear we're dealing with the timeout number.
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
30 seconds is just a bit too short if the tests are run with
KASAN and PROVE_LOCKING enabled, make it 60 seconds instead.
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Enable -Wextra and disable the unused parameter and different signedness
in comparison warnings.
Signed-off-by: Bart Van Assche <bvanassche@acm.org>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
After copying len(str) bytes of a string, the copy won't necessary have
\0 terminator, that makes test_pipe_io_fixed() to fail. Use memcmp().
Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Lifted this from blktests, basically it just checks for known patterns
of kernel complaints. If we trigger one while running a test, we fail
the test case.
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
This tests whether we can close an O_PATH opened fd. Test program
is an edited version of one from Clay Harris <bugs@claycon.org>, found
here:
https://claycon.org/software/io_uring/tests/close_opath.c
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
We submit both the read and write at the same time, there's no guarantee
the write is even started by the time the read is issued. Play it safe
and wait for the write before starting the read.
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
This new test checks if the mechanism to enable/disable notifications
through eventfd when a request is completed works correctly.
Signed-off-by: Stefano Garzarella <sgarzare@redhat.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Add it to .gitignore as well. This makes it easier to have a local
configuration that isn't overwritten by resetting the git tree, or
pulling changes.
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Helps to catch early if you're missing a module load or filesystem
mount.
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Check zero-length splice() and tee().
Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Add tee() tests with pipe data validation
Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Split and test functionality separately, better cover registered files
cases, and validate file\pipe actual data.
Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Depending on timing, we can get -EBADF from the waiting on a
completion. This is fine, as we've closed the ring itself, so we
cannot rely the completion coming in, it'll depend completely on
the timing of events.
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Just call it and check that it doesn't hang and returns success.
Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
We expect -EALREADY since an async worker was previously holding this
request, but for kernels with FASTPOLL (5.7+), we can successfully
cancel from the timeout. Allow -ETIME as well for the return value of
the linked timeout.
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Guillem reports that some new 32-bit architectures like armel and armhf
don't have mmap, just mmap2. Just use mmap() and let libc deal with
it, there's no reason why we need to call the specific mmap() system
call.
Reported-by: Guillem Jover <guillem@hadrons.org>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
If not there, don't build the test program test/statx
Fixes: https://github.com/axboe/liburing/issues/101
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Heavily based on test case from Dmitry Kadashev <dkadashev@gmail.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Heavily based on test case from Dmitry Kadashev <dkadashev@gmail.com>
Link: https://lore.kernel.org/io-uring/cc076d44-8cd0-1f19-2e79-45d2f0c5ace3@kernel.dk/T/#m894080c2370f51dd31cba85276d19b2720bc92a1
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
We just check for -EFAULT, but -ECANCELED is also OK and will happen
on later kernels since we check earlier there for prep and defer.
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|
|
This makes it clear it's a buffer group ID, and not some variant of
a credential related group ID.
Signed-off-by: Jens Axboe <axboe@kernel.dk>
|