aio: test closing the fd before destroying the ioctx

By closing the file descriptor before calling io_destroy, you pretty
much guarantee that the last put on the ioctx will be done in interrupt
context (during I/O completion).  This behavior has unearthed bugs in
the kernel in several different kernel versions, so let's add a test to
poke at it.

The original test case was provided by Matt Cross.  He has graciously
relicensed it under the GPL v2 or later so that it can be included in
xfstests.  I've modified the test a bit so that it would generate a
stable output format and to run for a fixed amount of time.

Signed-off-by: Jeff Moyer <jmoyer@redhat.com>
Reviewed-by: Brian Foster <bfoster@redhat.com>
Signed-off-by: Dave Chinner <david@fromorbit.com>
This commit is contained in:
Jeff Moyer
2014-08-13 11:00:38 +10:00
committed by Dave Chinner
parent 736a5b0d7c
commit 73bea923f3
4 changed files with 318 additions and 0 deletions
+1
View File
@@ -142,3 +142,4 @@
320 auto rw
321 auto quick metadata log
322 auto quick metadata log
323 auto aio stress