UPSTREAM: drm: virtio-gpu: transfer dumb buffers to host on plane update
For dumb buffers, we need to transfer them to the host when updating a plane. Signed-off-by: Rob Herring <robh@kernel.org> Signed-off-by: Dave Airlie <airlied@redhat.com> (cherry picked from commit 4109e7f7d5aeefaa1d72f9ab4c63aa5d79fc81fb) Change-Id: I125ccb3943d82ac1a7738e2afde28eea9e55abcc Signed-off-by: Alistair Strachan <astrachan@google.com>
This commit is contained in:
parent
9f7a117985
commit
c5707dc8d2
1 changed files with 7 additions and 0 deletions
|
@ -72,6 +72,13 @@ static void virtio_gpu_plane_atomic_update(struct drm_plane *plane,
|
|||
vgfb = to_virtio_gpu_framebuffer(plane->state->fb);
|
||||
bo = gem_to_virtio_gpu_obj(vgfb->obj);
|
||||
handle = bo->hw_res_handle;
|
||||
if (bo->dumb) {
|
||||
virtio_gpu_cmd_transfer_to_host_2d
|
||||
(vgdev, handle, 0,
|
||||
cpu_to_le32(plane->state->crtc_w),
|
||||
cpu_to_le32(plane->state->crtc_h),
|
||||
plane->state->crtc_x, plane->state->crtc_y, NULL);
|
||||
}
|
||||
} else {
|
||||
handle = 0;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue