]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
drm/virtio: fix endianness in primary_plane_update
authorMichael S. Tsirkin <mst@redhat.com>
Mon, 5 Dec 2016 19:44:39 +0000 (21:44 +0200)
committerMichael S. Tsirkin <mst@redhat.com>
Thu, 15 Dec 2016 04:59:16 +0000 (06:59 +0200)
virtio_gpu_cmd_transfer_to_host_2d expects x and y
parameters in LE, but virtio_gpu_primary_plane_update
passes in the CPU format instead.

Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
drivers/gpu/drm/virtio/virtgpu_plane.c

index cb75f0663ba0173314e82857cb235b0d646ef97e..11288ffa4af68fc5eb9557026d9a511c6ea1a63c 100644 (file)
@@ -88,8 +88,8 @@ static void virtio_gpu_primary_plane_update(struct drm_plane *plane,
                                (vgdev, handle, 0,
                                 cpu_to_le32(plane->state->src_w >> 16),
                                 cpu_to_le32(plane->state->src_h >> 16),
-                                plane->state->src_x >> 16,
-                                plane->state->src_y >> 16, NULL);
+                                cpu_to_le32(plane->state->src_x >> 16),
+                                cpu_to_le32(plane->state->src_y >> 16), NULL);
                }
        } else {
                handle = 0;