Home
last modified time | relevance | path

Searched refs:FALLOC_FL_KEEP_SIZE (Results 1 – 25 of 37) sorted by relevance

12

/linux/tools/testing/selftests/kvm/
H A Dguest_memfd_test.c63 ret = fallocate(fd, FALLOC_FL_KEEP_SIZE | FALLOC_FL_PUNCH_HOLE, 0, in test_mmap_supported()
143 kvm_fallocate(fd, FALLOC_FL_PUNCH_HOLE | FALLOC_FL_KEEP_SIZE, 0, page_size); in test_numa_allocation()
158 kvm_fallocate(fd, FALLOC_FL_PUNCH_HOLE | FALLOC_FL_KEEP_SIZE, 0, total_size); in test_numa_allocation()
227 ret = fallocate(fd, FALLOC_FL_KEEP_SIZE, 0, total_size); in test_fallocate()
230 ret = fallocate(fd, FALLOC_FL_KEEP_SIZE | FALLOC_FL_PUNCH_HOLE, in test_fallocate()
234 ret = fallocate(fd, FALLOC_FL_KEEP_SIZE, total_size, page_size); in test_fallocate()
237 ret = fallocate(fd, FALLOC_FL_KEEP_SIZE, total_size + page_size, page_size); in test_fallocate()
240 ret = fallocate(fd, FALLOC_FL_KEEP_SIZE | FALLOC_FL_PUNCH_HOLE, in test_fallocate()
244 ret = fallocate(fd, FALLOC_FL_KEEP_SIZE | FALLOC_FL_PUNCH_HOLE, in test_fallocate()
248 ret = fallocate(fd, FALLOC_FL_KEEP_SIZE | FALLOC_FL_PUNCH_HOLE, in test_fallocate()
[all …]
/linux/include/uapi/linux/
H A Dfalloc.h6 #define FALLOC_FL_KEEP_SIZE 0x01 /* default is extend size */ macro
/linux/tools/testing/selftests/kvm/x86/
H A Dprivate_mem_conversions_test.c431 kvm_fallocate(memfd, FALLOC_FL_KEEP_SIZE | FALLOC_FL_PUNCH_HOLE, 0, memfd_size); in test_mem_conversions()
432 kvm_fallocate(memfd, FALLOC_FL_KEEP_SIZE, 0, memfd_size); in test_mem_conversions()
/linux/block/
H A Dfops.c866 (FALLOC_FL_KEEP_SIZE | FALLOC_FL_PUNCH_HOLE | \
895 if (mode & FALLOC_FL_KEEP_SIZE) { in blkdev_fallocate()
913 case FALLOC_FL_ZERO_RANGE | FALLOC_FL_KEEP_SIZE: in blkdev_fallocate()
916 case FALLOC_FL_PUNCH_HOLE | FALLOC_FL_KEEP_SIZE: in blkdev_fallocate()
/linux/drivers/nvme/target/
H A Dio-cmd-file.c275 int mode = FALLOC_FL_PUNCH_HOLE | FALLOC_FL_KEEP_SIZE; in nvmet_file_execute_discard()
337 int mode = FALLOC_FL_ZERO_RANGE | FALLOC_FL_KEEP_SIZE; in nvmet_file_write_zeroes_work()
/linux/arch/um/os-Linux/
H A Dfile.c618 int n = fallocate(fd, FALLOC_FL_PUNCH_HOLE|FALLOC_FL_KEEP_SIZE, offset, len); in os_falloc_punch()
627 int n = fallocate(fd, FALLOC_FL_ZERO_RANGE|FALLOC_FL_KEEP_SIZE, offset, len); in os_falloc_zeroes()
/linux/fs/fat/
H A Dfile.c257 * space requests len bytes at offset. If FALLOC_FL_KEEP_SIZE is set
273 if (mode & ~FALLOC_FL_KEEP_SIZE) in fat_fallocate()
281 if (mode & FALLOC_FL_KEEP_SIZE) { in fat_fallocate()
/linux/fs/
H A Dioctl.c289 return vfs_fallocate(filp, mode | FALLOC_FL_KEEP_SIZE, sr.l_start, in ioctl_preallocate()
318 return vfs_fallocate(file, mode | FALLOC_FL_KEEP_SIZE, sr.l_start, sr.l_len); in compat_ioctl_preallocate()
/linux/tools/testing/selftests/mm/
H A Dhugetlb-madvise.c240 if (fallocate(fd, FALLOC_FL_PUNCH_HOLE | FALLOC_FL_KEEP_SIZE, in main()
H A Duffd-common.c46 FALLOC_FL_PUNCH_HOLE | FALLOC_FL_KEEP_SIZE, 0, in uffd_mem_fd_create()
/linux/virt/kvm/
H A Dguest_memfd.c304 if (!(mode & FALLOC_FL_KEEP_SIZE)) in kvm_gmem_fallocate()
307 if (mode & ~(FALLOC_FL_KEEP_SIZE | FALLOC_FL_PUNCH_HOLE)) in kvm_gmem_fallocate()
/linux/fs/gfs2/
H A Dfile.c1351 if (!(mode & FALLOC_FL_KEEP_SIZE) && (pos + count) > inode->i_size) in __gfs2_fallocate()
1376 if (mode & ~(FALLOC_FL_PUNCH_HOLE | FALLOC_FL_KEEP_SIZE)) in gfs2_fallocate()
1389 if (!(mode & FALLOC_FL_KEEP_SIZE) && in gfs2_fallocate()
/linux/fs/nfs/
H A Dnfs4file.c230 case FALLOC_FL_PUNCH_HOLE | FALLOC_FL_KEEP_SIZE: in nfs42_fallocate()
/linux/fs/fuse/
H A Dfile.c2938 (!(mode & FALLOC_FL_KEEP_SIZE) || in fuse_file_fallocate()
2941 if (mode & ~(FALLOC_FL_KEEP_SIZE | FALLOC_FL_PUNCH_HOLE | in fuse_file_fallocate()
2964 if (!(mode & FALLOC_FL_KEEP_SIZE) && in fuse_file_fallocate()
2975 if (!(mode & FALLOC_FL_KEEP_SIZE)) in fuse_file_fallocate()
2992 if (!(mode & FALLOC_FL_KEEP_SIZE)) { in fuse_file_fallocate()
3003 if (!(mode & FALLOC_FL_KEEP_SIZE)) in fuse_file_fallocate()
/linux/tools/testing/selftests/memfd/
H A Dmemfd_test.c512 FALLOC_FL_PUNCH_HOLE | FALLOC_FL_KEEP_SIZE, in mfd_assert_write()
577 FALLOC_FL_PUNCH_HOLE | FALLOC_FL_KEEP_SIZE, in mfd_fail_write()
/linux/fs/ntfs3/
H A Dfile.c562 * space requests 'len' bytes at 'vbo'. If FALLOC_FL_KEEP_SIZE is set
597 ~(FALLOC_FL_KEEP_SIZE | FALLOC_FL_PUNCH_HOLE | in ntfs_fallocate()
784 if (mode & FALLOC_FL_KEEP_SIZE) { in ntfs_fallocate()
/linux/fs/hugetlbfs/
H A Dinode.c747 if (mode & ~(FALLOC_FL_KEEP_SIZE | FALLOC_FL_PUNCH_HOLE)) in hugetlbfs_fallocate()
852 if (!(mode & FALLOC_FL_KEEP_SIZE) && offset + len > inode->i_size) in hugetlbfs_fallocate()
/linux/fs/xfs/
H A Dxfs_file.c1193 if ((mode & FALLOC_FL_KEEP_SIZE) || offset + len <= i_size_read(inode)) in xfs_falloc_collapse_range()
1410 (FALLOC_FL_ALLOCATE_RANGE | FALLOC_FL_KEEP_SIZE | \ in __xfs_file_fallocate()
/linux/fs/cachefiles/
H A Dio.c585 ret = vfs_fallocate(file, FALLOC_FL_PUNCH_HOLE | FALLOC_FL_KEEP_SIZE, in __cachefiles_prepare_write()
/linux/fs/smb/server/
H A Dvfs.c925 FALLOC_FL_PUNCH_HOLE | FALLOC_FL_KEEP_SIZE, in ksmbd_vfs_set_fadvise()
929 FALLOC_FL_ZERO_RANGE | FALLOC_FL_KEEP_SIZE, in ksmbd_vfs_zero_data()
/linux/drivers/target/
H A Dtarget_core_file.c568 int mode = FALLOC_FL_PUNCH_HOLE | FALLOC_FL_KEEP_SIZE; in fd_execute_unmap()
/linux/tools/testing/selftests/kvm/lib/
H A Dkvm_util.c864 kvm_fallocate(fd, FALLOC_FL_PUNCH_HOLE | FALLOC_FL_KEEP_SIZE, 0, size); in vm_userspace_mem_region_hva_insert()
1286 const int mode = FALLOC_FL_KEEP_SIZE | (punch_hole ? FALLOC_FL_PUNCH_HOLE : 0); in vcpu_mmap_sz()
/linux/tools/testing/selftests/kvm/arm64/
H A Dpage_fault_test.c414 ret = fallocate(fd, FALLOC_FL_PUNCH_HOLE | FALLOC_FL_KEEP_SIZE, in punch_hole_in_backing_store()
/linux/fs/btrfs/
H A Dfile.c2865 if (mode & FALLOC_FL_KEEP_SIZE || end <= i_size_read(inode)) in btrfs_fallocate_update_isize()
3130 if (mode & ~(FALLOC_FL_KEEP_SIZE | FALLOC_FL_PUNCH_HOLE | in btrfs_fallocate()
3139 if (!(mode & FALLOC_FL_KEEP_SIZE) && offset + len > inode->i_size) { in btrfs_fallocate()
/linux/fs/ocfs2/
H A Dfile.c2125 if (mode & ~(FALLOC_FL_KEEP_SIZE | FALLOC_FL_PUNCH_HOLE)) in ocfs2_fallocate()
2130 if (mode & FALLOC_FL_KEEP_SIZE) { in ocfs2_fallocate()

12