xfstests: generic/315, verify preallocated disk space is released per truncate

Introduce generic test 315 to verify if the disk space is
released after truncating a preallocated file back to the
old smaller size.  Before Linux-3.10, Btrfs/OCFS2 test
failed in this case.

The test file is fallocated with FALLOC_FL_KEEP_SIZE option.

Signed-off-by: Jie Liu <jeff.liu@oracle.com>
Reviewed-by: Ben Myers <bpm@sgi.com>
Signed-off-by: Ben Myers <bpm@sgi.com>
This commit is contained in:
Jie Liu
2013-07-01 18:29:19 +08:00
committed by Ben Myers
parent b7ff5113a7
commit 6fe0ad6faf
3 changed files with 82 additions and 0 deletions
+1
View File
@@ -117,3 +117,4 @@
312 auto quick prealloc enospc
313 auto quick
314 auto quick acl
315 auto quick rw prealloc