diff options
author | Chia-I Wu <olvaffe@gmail.com> | 2022-08-31 12:06:01 -0700 |
---|---|---|
committer | Gerd Hoffmann <kraxel@redhat.com> | 2022-09-07 12:13:22 +0200 |
commit | 85faca8ca0f659263b5fb2385e4c231cc075bd84 (patch) | |
tree | 84d4a6305adbf685c2dc8c6f4a0c05b75ce4663f /drivers/gpu/drm/virtio/virtgpu_display.c | |
parent | fad08d6248f88c9420eff5471ad34978a5c6c805 (diff) |
drm/virtio: set fb_modifiers_not_supported
Without this, the drm core advertises LINEAR modifier which is
incorrect.
Also userspace virgl does not support modifiers. For example, it causes
chrome on ozone/drm to fail with "Failed to create scanout buffer".
Fixes: 2af104290da5 ("drm: introduce fb_modifiers_not_supported flag in mode_config")
Suggested-by: Shao-Chuan Lee <shaochuan@chromium.org>
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
Link: http://patchwork.freedesktop.org/patch/msgid/20220831190601.1295129-1-olvaffe@gmail.com
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/virtio/virtgpu_display.c')
-rw-r--r-- | drivers/gpu/drm/virtio/virtgpu_display.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/gpu/drm/virtio/virtgpu_display.c b/drivers/gpu/drm/virtio/virtgpu_display.c index 5c7f198c0712..9ea7611a9e0f 100644 --- a/drivers/gpu/drm/virtio/virtgpu_display.c +++ b/drivers/gpu/drm/virtio/virtgpu_display.c @@ -349,6 +349,8 @@ int virtio_gpu_modeset_init(struct virtio_gpu_device *vgdev) vgdev->ddev->mode_config.max_width = XRES_MAX; vgdev->ddev->mode_config.max_height = YRES_MAX; + vgdev->ddev->mode_config.fb_modifiers_not_supported = true; + for (i = 0 ; i < vgdev->num_scanouts; ++i) vgdev_output_init(vgdev, i); |