mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/herbert/cryptodev-2.6.git
synced 2026-04-18 11:33:36 -04:00
drm/virtio: batch plane updates (pageflip)
Move virtio_gpu_notify() to higher-level functions for
virtio_gpu_cmd_resource_flush(), virtio_gpu_cmd_set_scanout() and
virtio_gpu_cmd_transfer_to_host_{2d,3d}().
virtio_gpu_primary_plane_update() will notify only once for a series
of commands (restores plane update command batching).
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Reviewed-by: Chia-I Wu <olvaffe@gmail.com>
Reviewed-by: Gurchetan Singh <gurchetansingh@chromium.org>
Link: http://patchwork.freedesktop.org/patch/msgid/20200214125535.26349-4-kraxel@redhat.com
This commit is contained in:
@@ -90,6 +90,7 @@ static void virtio_gpu_crtc_mode_set_nofb(struct drm_crtc *crtc)
|
||||
virtio_gpu_cmd_set_scanout(vgdev, output->index, 0,
|
||||
crtc->mode.hdisplay,
|
||||
crtc->mode.vdisplay, 0, 0);
|
||||
virtio_gpu_notify(vgdev);
|
||||
}
|
||||
|
||||
static void virtio_gpu_crtc_atomic_enable(struct drm_crtc *crtc,
|
||||
@@ -108,6 +109,7 @@ static void virtio_gpu_crtc_atomic_disable(struct drm_crtc *crtc,
|
||||
struct virtio_gpu_output *output = drm_crtc_to_virtio_gpu_output(crtc);
|
||||
|
||||
virtio_gpu_cmd_set_scanout(vgdev, output->index, 0, 0, 0, 0, 0);
|
||||
virtio_gpu_notify(vgdev);
|
||||
output->enabled = false;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user