reflink: test that CoW writes fail when we're out of space

Ensure that copy-on-writing a reflinked file when there's no free disk
space reflects the desired ENOSPC back to userspace during the write
call.  Tests the buffered IO, direct IO, and mmap write paths.

Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Acked-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Dave Chinner <david@fromorbit.com>
This commit is contained in:
Darrick J. Wong
2015-11-17 08:40:08 +11:00
committed by Dave Chinner
parent 5fb5ee48b3
commit db4284f312
9 changed files with 472 additions and 0 deletions
+8
View File
@@ -0,0 +1,8 @@
QA output created by 173
Format and mount
Reformat with appropriate size
Create a big file and reflink it
Allocate the rest of the space
mmap CoW the big file
Remount and try CoW again
Check scratch fs