]> www.infradead.org Git - users/dwmw2/linux.git/commit
xfs: map unwritten blocks in XFS_IOC_{ALLOC,FREE}SP just like fallocate
authorDarrick J. Wong <djwong@kernel.org>
Wed, 22 Dec 2021 22:19:18 +0000 (14:19 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 11 Jan 2022 12:58:49 +0000 (13:58 +0100)
commit1c3564fca0e7b8c9e96245a2cb35e198b036ee9a
tree85cea1c929bc0d4a480e419df9b6793e70432fb9
parent9e0a27bfbe9032ac766f6ef2e67404042f6da2d6
xfs: map unwritten blocks in XFS_IOC_{ALLOC,FREE}SP just like fallocate

commit 983d8e60f50806f90534cc5373d0ce867e5aaf79 upstream.

The old ALLOCSP/FREESP ioctls in XFS can be used to preallocate space at
the end of files, just like fallocate and RESVSP.  Make the behavior
consistent with the other ioctls.

Reported-by: Kirill Tkhai <ktkhai@virtuozzo.com>
Signed-off-by: Darrick J. Wong <djwong@kernel.org>
Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Reviewed-by: Eric Sandeen <sandeen@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
fs/xfs/xfs_ioctl.c