diff options
author | Gerd Hoffmann <kraxel@redhat.com> | 2020-02-07 08:46:38 +0100 |
---|---|---|
committer | Gerd Hoffmann <kraxel@redhat.com> | 2020-02-10 12:54:33 +0100 |
commit | 2f2aa13724d56829d910b2fa8e80c502d388f106 (patch) | |
tree | 6c7eeb0793a3ebfcd217211c2cd61c96e1f21758 /drivers/gpu/drm/virtio/virtgpu_drv.h | |
parent | 2fe4ca9d0e4d62bba4d263e35db356ae74024979 (diff) | |
download | linux-2f2aa13724d56829d910b2fa8e80c502d388f106.tar.gz |
drm/virtio: move virtio_gpu_mem_entry initialization to new function
Introduce new virtio_gpu_object_shmem_init() helper function which will
create the virtio_gpu_mem_entry array, containing the backing storage
information for the host. For the most path this just moves code from
virtio_gpu_object_attach().
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Link: http://patchwork.freedesktop.org/patch/msgid/20200207074638.26386-5-kraxel@redhat.com
Reviewed-by: Chia-I Wu <olvaffe@gmail.com>
Diffstat (limited to 'drivers/gpu/drm/virtio/virtgpu_drv.h')
-rw-r--r-- | drivers/gpu/drm/virtio/virtgpu_drv.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/gpu/drm/virtio/virtgpu_drv.h b/drivers/gpu/drm/virtio/virtgpu_drv.h index cab18c23064b..7fd8361e1c9e 100644 --- a/drivers/gpu/drm/virtio/virtgpu_drv.h +++ b/drivers/gpu/drm/virtio/virtgpu_drv.h @@ -71,6 +71,7 @@ struct virtio_gpu_object { struct sg_table *pages; uint32_t mapped; + bool dumb; bool created; }; @@ -281,7 +282,8 @@ void virtio_gpu_cmd_set_scanout(struct virtio_gpu_device *vgdev, uint32_t x, uint32_t y); int virtio_gpu_object_attach(struct virtio_gpu_device *vgdev, struct virtio_gpu_object *obj, - struct virtio_gpu_fence *fence); + struct virtio_gpu_mem_entry *ents, + unsigned int nents); int virtio_gpu_attach_status_page(struct virtio_gpu_device *vgdev); int virtio_gpu_detach_status_page(struct virtio_gpu_device *vgdev); void virtio_gpu_cursor_ping(struct virtio_gpu_device *vgdev, |