]> git.apps.os.sepia.ceph.com Git - xfstests-dev.git/commit
generic/275: writes may not partially succeed
authorDave Chinner <dchinner@redhat.com>
Tue, 26 May 2015 02:51:56 +0000 (12:51 +1000)
committerDave Chinner <david@fromorbit.com>
Tue, 26 May 2015 02:51:56 +0000 (12:51 +1000)
commit9816be53e531d26509d41645c2b829e511491cd6
treeea092c48d71be65c11a855354b9b2529552e1a05
parent6bd4b513af0478fb5f44b535ceea12a5b3b94165
generic/275: writes may not partially succeed

When a large IO is done as a single buffer, there is no guarantee
that it will partially succeed when close to ENOSPC. The test
assumes that the kernel is going to break the write down into
smaller chunks (i.e. buffered IO breaking it down into PAGE_SIZE
allocations), but certain configurations will not do this. e.g.
extent size hints are set or DAX is being used) and hence the large
write fails completely as there is not space for the entire
allocation to be made.

Hence break the final write in the test up into multiple small
writes, thereby acheiving the same effect - ensuring that we can
write more data after removing some space....

Signed-off-by: Dave Chinner <dchinner@redhat.com>
Reviewed-by: Brian Foster <bfoster@redhat.com>
Signed-off-by: Dave Chinner <david@fromorbit.com>
tests/generic/275