ceph: add additional range check in ceph_fallocate()
authorChengguang Xu <cgxu519@gmx.com>
Thu, 19 Jul 2018 14:15:25 +0000 (22:15 +0800)
committerIlya Dryomov <idryomov@gmail.com>
Thu, 2 Aug 2018 19:33:28 +0000 (21:33 +0200)
commit0671e9968dfb3f99a366df816c361b8e871dba1b
tree5abae989553cfe457b8da5d85af9af52ad969943
parent719784ba706cdbb47ef87483950f0a4594d36e87
ceph: add additional range check in ceph_fallocate()

If the range is larger than both real file size and limit of
max file size, then return -EFBIG.

Signed-off-by: Chengguang Xu <cgxu519@gmx.com>
Reviewed-by: "Yan, Zheng" <zyan@redhat.com>
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
fs/ceph/file.c