[PATCH 3/3] drm/virtio: delete notify in virtio_gpu_object_create

Gurchetan Singh gurchetansingh at chromium.org
Tue Mar 24 16:44:00 UTC 2020


- For dumb buffers, virtio_gpu_gem_create can notify.
- For 3D buffers, virtio_gpu_gem_object_open can notify.

Signed-off-by: Gurchetan Singh <gurchetansingh at chromium.org>
---
 drivers/gpu/drm/virtio/virtgpu_gem.c    | 1 +
 drivers/gpu/drm/virtio/virtgpu_object.c | 1 -
 2 files changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/virtio/virtgpu_gem.c b/drivers/gpu/drm/virtio/virtgpu_gem.c
index 90c0a8ea1708..aa14dd12928e 100644
--- a/drivers/gpu/drm/virtio/virtgpu_gem.c
+++ b/drivers/gpu/drm/virtio/virtgpu_gem.c
@@ -49,6 +49,7 @@ static int virtio_gpu_gem_create(struct drm_file *file,
 		return ret;
 	}
 
+	virtio_gpu_notify(vgdev);
 	*obj_p = &obj->base.base;
 
 	/* drop reference from allocate - handle holds it now */
diff --git a/drivers/gpu/drm/virtio/virtgpu_object.c b/drivers/gpu/drm/virtio/virtgpu_object.c
index d9039bb7c5e3..51a8da7d5ef3 100644
--- a/drivers/gpu/drm/virtio/virtgpu_object.c
+++ b/drivers/gpu/drm/virtio/virtgpu_object.c
@@ -241,7 +241,6 @@ int virtio_gpu_object_create(struct virtio_gpu_device *vgdev,
 		return ret;
 	}
 
-	virtio_gpu_notify(vgdev);
 	*bo_ptr = bo;
 	return 0;
 
-- 
2.25.1.696.g5e7596f4ac-goog



More information about the dri-devel mailing list