drm/virtio: drop resource_id argument.

We pass the obj anyway, so obj->hw_res_handle can be used instead
in virtio_gpu_object_attach() and virtio_gpu_cmd_create_resource().

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Reviewed-by: Dave Airlie <airlied@redhat.com>
Link: http://patchwork.freedesktop.org/patch/msgid/20181019061847.18958-6-kraxel@redhat.com
This commit is contained in:
Gerd Hoffmann 2018-10-19 08:18:46 +02:00
parent 70a0d6a377
commit 724cfdfd66
6 changed files with 10 additions and 16 deletions

View file

@ -104,11 +104,11 @@ int virtio_gpu_mode_dumb_create(struct drm_file *file_priv,
format = virtio_gpu_translate_format(DRM_FORMAT_HOST_XRGB8888);
obj = gem_to_virtio_gpu_obj(gobj);
virtio_gpu_resource_id_get(vgdev, &obj->hw_res_handle);
virtio_gpu_cmd_create_resource(vgdev, obj, obj->hw_res_handle, format,
virtio_gpu_cmd_create_resource(vgdev, obj, format,
args->width, args->height);
/* attach the object to the resource */
ret = virtio_gpu_object_attach(vgdev, obj, obj->hw_res_handle, NULL);
ret = virtio_gpu_object_attach(vgdev, obj, NULL);
if (ret)
goto fail;