Skip to content

Commit 92c1354

Browse files
committed
drm/qxl: Run DRM default client setup
Call drm_client_setup() to run the kernel's default client setup for DRM. Set fbdev_probe in struct drm_driver, so that the client setup can start the common fbdev client. The qxl driver specifies a preferred color mode of 32. As this is the default if no format has been given, leave it out entirely. v5: - select DRM_CLIENT_SELECTION Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Cc: Dave Airlie <airlied@redhat.com> Cc: Gerd Hoffmann <kraxel@redhat.com> Acked-by: Javier Martinez Canillas <javierm@redhat.com> Link: https://patchwork.freedesktop.org/patch/msgid/20240924071734.98201-70-tzimmermann@suse.de
1 parent ef35089 commit 92c1354

2 files changed

Lines changed: 4 additions & 1 deletion

File tree

drivers/gpu/drm/qxl/Kconfig

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
config DRM_QXL
33
tristate "QXL virtual GPU"
44
depends on DRM && PCI && MMU
5+
select DRM_CLIENT_SELECTION
56
select DRM_KMS_HELPER
67
select DRM_TTM
78
select DRM_TTM_HELPER

drivers/gpu/drm/qxl/qxl_drv.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@
3636
#include <drm/drm.h>
3737
#include <drm/drm_aperture.h>
3838
#include <drm/drm_atomic_helper.h>
39+
#include <drm/drm_client_setup.h>
3940
#include <drm/drm_drv.h>
4041
#include <drm/drm_fbdev_ttm.h>
4142
#include <drm/drm_file.h>
@@ -118,7 +119,7 @@ qxl_pci_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
118119
if (ret)
119120
goto modeset_cleanup;
120121

121-
drm_fbdev_ttm_setup(&qdev->ddev, 32);
122+
drm_client_setup(&qdev->ddev, NULL);
122123
return 0;
123124

124125
modeset_cleanup:
@@ -293,6 +294,7 @@ static struct drm_driver qxl_driver = {
293294
.debugfs_init = qxl_debugfs_init,
294295
#endif
295296
.gem_prime_import_sg_table = qxl_gem_prime_import_sg_table,
297+
DRM_FBDEV_TTM_DRIVER_OPS,
296298
.fops = &qxl_fops,
297299
.ioctls = qxl_ioctls,
298300
.num_ioctls = ARRAY_SIZE(qxl_ioctls),

0 commit comments

Comments
 (0)