Commit fcdd19b8 authored by Gerd Hoffmann's avatar Gerd Hoffmann
Browse files

drm/virtio: notify before waiting



Before we are going to wait for virtqueue entries becoming available
call virtio_gpu_notify() to make sure the host has seen everything
we've submitted.

Signed-off-by: default avatarGerd Hoffmann <kraxel@redhat.com>
Reviewed-by: default avatarChia-I Wu <olvaffe@gmail.com>
Reviewed-by: default avatarGurchetan Singh <gurchetansingh@chromium.org>
Link: http://patchwork.freedesktop.org/patch/msgid/20200214125535.26349-3-kraxel@redhat.com
parent cca41da1
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -346,6 +346,7 @@ again:

	if (vq->num_free < elemcnt) {
		spin_unlock(&vgdev->ctrlq.qlock);
		virtio_gpu_notify(vgdev);
		wait_event(vgdev->ctrlq.ack_queue, vq->num_free >= elemcnt);
		goto again;
	}