diff options
Diffstat (limited to 'fs/ceph/file.c')
| -rw-r--r-- | fs/ceph/file.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/ceph/file.c b/fs/ceph/file.c index 72cc67ab4ead..fdbf4aeaa408 100644 --- a/fs/ceph/file.c +++ b/fs/ceph/file.c @@ -140,7 +140,7 @@ static ssize_t iter_get_bvecs_alloc(struct iov_iter *iter, size_t maxsize, * __iter_get_bvecs() may populate only part of the array -- zero it * out. */ - bv = kvmalloc_array(npages, sizeof(*bv), GFP_KERNEL | __GFP_ZERO); + bv = kvmalloc_objs(*bv, npages, GFP_KERNEL | __GFP_ZERO); if (!bv) return -ENOMEM; @@ -1344,7 +1344,7 @@ static void ceph_aio_complete_req(struct ceph_osd_request *req) struct ceph_aio_work *aio_work; BUG_ON(!aio_req->write); - aio_work = kmalloc(sizeof(*aio_work), GFP_NOFS); + aio_work = kmalloc_obj(*aio_work, GFP_NOFS); if (aio_work) { INIT_WORK(&aio_work->work, ceph_aio_retry_work); aio_work->req = req; @@ -1572,7 +1572,7 @@ ceph_direct_read_write(struct kiocb *iocb, struct iov_iter *iter, */ if (pos == iocb->ki_pos && !is_sync_kiocb(iocb) && (len == count || pos + count <= i_size_read(inode))) { - aio_req = kzalloc(sizeof(*aio_req), GFP_KERNEL); + aio_req = kzalloc_obj(*aio_req, GFP_KERNEL); if (aio_req) { aio_req->iocb = iocb; aio_req->write = write; |
