Commit 6457a0df authored by Gurchetan Singh's avatar Gurchetan Singh Committed by Gerd Hoffmann

drm/virtio: delete notify in virtio_gpu_object_create

For 3D buffers, virtio_gpu_gem_object_open notifies.
We can have the same behavior for dumb buffer.

v2: virtio_gpu_gem_object_open always notifies
v3: avoid boolean variable
Signed-off-by: default avatarGurchetan Singh <gurchetansingh@chromium.org>
Reviewed-by: default avatarChia-I Wu <olvaffe@gmail.com>
Link: http://patchwork.freedesktop.org/patch/msgid/20200401223039.2860-3-gurchetansingh@chromium.orgSigned-off-by: default avatarGerd Hoffmann <kraxel@redhat.com>
parent 6eefb4bb
...@@ -114,7 +114,7 @@ int virtio_gpu_gem_object_open(struct drm_gem_object *obj, ...@@ -114,7 +114,7 @@ int virtio_gpu_gem_object_open(struct drm_gem_object *obj,
struct virtio_gpu_object_array *objs; struct virtio_gpu_object_array *objs;
if (!vgdev->has_virgl_3d) if (!vgdev->has_virgl_3d)
return 0; goto out_notify;
objs = virtio_gpu_array_alloc(1); objs = virtio_gpu_array_alloc(1);
if (!objs) if (!objs)
...@@ -123,6 +123,7 @@ int virtio_gpu_gem_object_open(struct drm_gem_object *obj, ...@@ -123,6 +123,7 @@ int virtio_gpu_gem_object_open(struct drm_gem_object *obj,
virtio_gpu_cmd_context_attach_resource(vgdev, vfpriv->ctx_id, virtio_gpu_cmd_context_attach_resource(vgdev, vfpriv->ctx_id,
objs); objs);
out_notify:
virtio_gpu_notify(vgdev); virtio_gpu_notify(vgdev);
return 0; return 0;
} }
......
...@@ -241,7 +241,6 @@ int virtio_gpu_object_create(struct virtio_gpu_device *vgdev, ...@@ -241,7 +241,6 @@ int virtio_gpu_object_create(struct virtio_gpu_device *vgdev,
return ret; return ret;
} }
virtio_gpu_notify(vgdev);
*bo_ptr = bo; *bo_ptr = bo;
return 0; return 0;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment