All of lore.kernel.org
 help / color / mirror / Atom feed
From: Gerd Hoffmann <kraxel@redhat.com>
To: dri-devel@lists.freedesktop.org
Cc: gurchetansingh@chromium.org, olvaffe@gmail.com,
	Gerd Hoffmann <kraxel@redhat.com>,
	David Airlie <airlied@linux.ie>, Daniel Vetter <daniel@ffwll.ch>,
	"open list:VIRTIO GPU DRIVER"
	<virtualization@lists.linux-foundation.org>,
	open list <linux-kernel@vger.kernel.org>
Subject: [PATCH v4 2/6] drm/virtio: notify before waiting
Date: Fri, 14 Feb 2020 13:55:31 +0100	[thread overview]
Message-ID: <20200214125535.26349-3-kraxel@redhat.com> (raw)
In-Reply-To: <20200214125535.26349-1-kraxel@redhat.com>

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: Gerd Hoffmann <kraxel@redhat.com>
---
 drivers/gpu/drm/virtio/virtgpu_vq.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/gpu/drm/virtio/virtgpu_vq.c b/drivers/gpu/drm/virtio/virtgpu_vq.c
index 6cc259cfa517..653efb26bcd9 100644
--- a/drivers/gpu/drm/virtio/virtgpu_vq.c
+++ b/drivers/gpu/drm/virtio/virtgpu_vq.c
@@ -346,6 +346,7 @@ static void virtio_gpu_queue_ctrl_sgs(struct virtio_gpu_device *vgdev,
 
 	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;
 	}
-- 
2.18.2

WARNING: multiple messages have this Message-ID (diff)
From: Gerd Hoffmann <kraxel@redhat.com>
To: dri-devel@lists.freedesktop.org
Cc: David Airlie <airlied@linux.ie>,
	open list <linux-kernel@vger.kernel.org>,
	"open list:VIRTIO GPU DRIVER"
	<virtualization@lists.linux-foundation.org>,
	Gerd Hoffmann <kraxel@redhat.com>,
	gurchetansingh@chromium.org
Subject: [PATCH v4 2/6] drm/virtio: notify before waiting
Date: Fri, 14 Feb 2020 13:55:31 +0100	[thread overview]
Message-ID: <20200214125535.26349-3-kraxel@redhat.com> (raw)
In-Reply-To: <20200214125535.26349-1-kraxel@redhat.com>

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: Gerd Hoffmann <kraxel@redhat.com>
---
 drivers/gpu/drm/virtio/virtgpu_vq.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/gpu/drm/virtio/virtgpu_vq.c b/drivers/gpu/drm/virtio/virtgpu_vq.c
index 6cc259cfa517..653efb26bcd9 100644
--- a/drivers/gpu/drm/virtio/virtgpu_vq.c
+++ b/drivers/gpu/drm/virtio/virtgpu_vq.c
@@ -346,6 +346,7 @@ static void virtio_gpu_queue_ctrl_sgs(struct virtio_gpu_device *vgdev,
 
 	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;
 	}
-- 
2.18.2

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

WARNING: multiple messages have this Message-ID (diff)
From: Gerd Hoffmann <kraxel@redhat.com>
To: dri-devel@lists.freedesktop.org
Cc: gurchetansingh@chromium.org, olvaffe@gmail.com,
	Gerd Hoffmann <kraxel@redhat.com>,
	David Airlie <airlied@linux.ie>, Daniel Vetter <daniel@ffwll.ch>,
	virtualization@lists.linux-foundation.org (open list:VIRTIO GPU
	DRIVER), linux-kernel@vger.kernel.org (open list)
Subject: [PATCH v4 2/6] drm/virtio: notify before waiting
Date: Fri, 14 Feb 2020 13:55:31 +0100	[thread overview]
Message-ID: <20200214125535.26349-3-kraxel@redhat.com> (raw)
In-Reply-To: <20200214125535.26349-1-kraxel@redhat.com>

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: Gerd Hoffmann <kraxel@redhat.com>
---
 drivers/gpu/drm/virtio/virtgpu_vq.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/gpu/drm/virtio/virtgpu_vq.c b/drivers/gpu/drm/virtio/virtgpu_vq.c
index 6cc259cfa517..653efb26bcd9 100644
--- a/drivers/gpu/drm/virtio/virtgpu_vq.c
+++ b/drivers/gpu/drm/virtio/virtgpu_vq.c
@@ -346,6 +346,7 @@ static void virtio_gpu_queue_ctrl_sgs(struct virtio_gpu_device *vgdev,
 
 	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;
 	}
-- 
2.18.2


  parent reply	other threads:[~2020-02-14 12:55 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-14 12:55 [PATCH v4 0/6] drm/virtio: rework batching Gerd Hoffmann
2020-02-14 12:55 ` [PATCH v4 1/6] drm/virtio: rework notification for better batching Gerd Hoffmann
2020-02-14 12:55   ` Gerd Hoffmann
2020-02-14 12:55   ` Gerd Hoffmann
2020-02-14 12:55 ` Gerd Hoffmann [this message]
2020-02-14 12:55   ` [PATCH v4 2/6] drm/virtio: notify before waiting Gerd Hoffmann
2020-02-14 12:55   ` Gerd Hoffmann
2020-02-14 12:55 ` [PATCH v4 3/6] drm/virtio: batch plane updates (pageflip) Gerd Hoffmann
2020-02-14 12:55   ` Gerd Hoffmann
2020-02-14 12:55   ` Gerd Hoffmann
2020-02-14 12:55 ` [PATCH v4 4/6] drm/virtio: batch resource creation Gerd Hoffmann
2020-02-14 12:55   ` Gerd Hoffmann
2020-02-14 12:55   ` Gerd Hoffmann
2020-02-14 12:55 ` [PATCH v4 5/6] drm/virtio: batch display query Gerd Hoffmann
2020-02-14 12:55   ` Gerd Hoffmann
2020-02-14 12:55   ` Gerd Hoffmann
2020-02-14 12:55 ` [PATCH v4 6/6] drm/virtio: move remaining virtio_gpu_notify calls Gerd Hoffmann
2020-02-14 12:55   ` Gerd Hoffmann
2020-02-14 12:55   ` Gerd Hoffmann
2020-02-14 19:44 ` [PATCH v4 0/6] drm/virtio: rework batching Chia-I Wu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20200214125535.26349-3-kraxel@redhat.com \
    --to=kraxel@redhat.com \
    --cc=airlied@linux.ie \
    --cc=daniel@ffwll.ch \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=gurchetansingh@chromium.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=olvaffe@gmail.com \
    --cc=virtualization@lists.linux-foundation.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.