summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/virtio/virtgpu_ioctl.c
diff options
context:
space:
mode:
authorGerd Hoffmann <kraxel@redhat.com>2019-08-29 13:32:58 +0300
committerGerd Hoffmann <kraxel@redhat.com>2019-09-04 07:54:11 +0300
commit2e0d9ee457851ca0afbfec59466e9e7cae734389 (patch)
treefd767b971accb919455ff38587509f3ea8c9ae1b /drivers/gpu/drm/virtio/virtgpu_ioctl.c
parentc66df701e783bc666593e6e665f13670760883ee (diff)
downloadlinux-2e0d9ee457851ca0afbfec59466e9e7cae734389.tar.xz
drm/virtio: remove virtio_gpu_alloc_object
Thin wrapper around virtio_gpu_object_create(), but calling that directly works equally well. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> Reviewed-by: Chia-I Wu <olvaffe@gmail.com> Link: http://patchwork.freedesktop.org/patch/msgid/20190829103301.3539-16-kraxel@redhat.com
Diffstat (limited to 'drivers/gpu/drm/virtio/virtgpu_ioctl.c')
-rw-r--r--drivers/gpu/drm/virtio/virtgpu_ioctl.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/gpu/drm/virtio/virtgpu_ioctl.c b/drivers/gpu/drm/virtio/virtgpu_ioctl.c
index 588a4ba1e7a4..f5083c538f9c 100644
--- a/drivers/gpu/drm/virtio/virtgpu_ioctl.c
+++ b/drivers/gpu/drm/virtio/virtgpu_ioctl.c
@@ -256,10 +256,10 @@ static int virtio_gpu_resource_create_ioctl(struct drm_device *dev, void *data,
fence = virtio_gpu_fence_alloc(vgdev);
if (!fence)
return -ENOMEM;
- qobj = virtio_gpu_alloc_object(dev, &params, fence);
+ ret = virtio_gpu_object_create(vgdev, &params, &qobj, fence);
dma_fence_put(&fence->f);
- if (IS_ERR(qobj))
- return PTR_ERR(qobj);
+ if (ret < 0)
+ return ret;
obj = &qobj->base.base;
ret = drm_gem_handle_create(file_priv, obj, &handle);