dpy_gl_frame_counter needs to be called for guest scanout frame count
to calculate and display the performance figure - ups, the guest FB
update per seconds.

Signed-off-by: Dongwon Kim <dongwon....@intel.com>
---
 hw/display/virtio-gpu.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/hw/display/virtio-gpu.c b/hw/display/virtio-gpu.c
index e183f4ecda..722869864a 100644
--- a/hw/display/virtio-gpu.c
+++ b/hw/display/virtio-gpu.c
@@ -523,6 +523,7 @@ static void virtio_gpu_resource_flush(VirtIOGPU *g,
                 console_has_gl(scanout->con)) {
                 dpy_gl_update(scanout->con, 0, 0, scanout->width,
                               scanout->height);
+                dpy_gl_count_frame(scanout->con, true);
                 return;
             }
         }
@@ -566,6 +567,7 @@ static void virtio_gpu_resource_flush(VirtIOGPU *g,
                        extents->x1, extents->y1,
                        extents->x2 - extents->x1,
                        extents->y2 - extents->y1);
+        dpy_gl_count_frame(scanout->con, true);
 
         pixman_region_fini(&region);
         pixman_region_fini(&finalregion);
-- 
2.17.1


Reply via email to