]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
drm/arm/malidp: Run DRM default client setup
authorThomas Zimmermann <tzimmermann@suse.de>
Tue, 24 Sep 2024 07:12:07 +0000 (09:12 +0200)
committerThomas Zimmermann <tzimmermann@suse.de>
Thu, 26 Sep 2024 06:27:55 +0000 (08:27 +0200)
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 malidp 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: Liviu Dudau <liviu.dudau@arm.com>
Acked-by: Liviu Dudau <liviu.dudau@arm.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20240924071734.98201-10-tzimmermann@suse.de
drivers/gpu/drm/arm/Kconfig
drivers/gpu/drm/arm/malidp_drv.c

index ed218e5f790102fd54e2e776fa3deb9bc490d97a..c901ac00c0c3a8f356bd53d97305c6b39b3e6662 100644 (file)
@@ -28,6 +28,7 @@ config DRM_MALI_DISPLAY
        tristate "ARM Mali Display Processor"
        depends on DRM && OF && (ARM || ARM64 || COMPILE_TEST)
        depends on COMMON_CLK
+       select DRM_CLIENT_SELECTION
        select DRM_KMS_HELPER
        select DRM_GEM_DMA_HELPER
        select VIDEOMODE_HELPERS
index 6682131d29104464a30f66d512782d785b4e4120..4cb25004b84fec2c83ddaa1ac06179d3c5ebe866 100644 (file)
@@ -18,6 +18,7 @@
 
 #include <drm/drm_atomic.h>
 #include <drm/drm_atomic_helper.h>
+#include <drm/drm_client_setup.h>
 #include <drm/drm_crtc.h>
 #include <drm/drm_drv.h>
 #include <drm/drm_fbdev_dma.h>
@@ -562,6 +563,7 @@ static void malidp_debugfs_init(struct drm_minor *minor)
 static const struct drm_driver malidp_driver = {
        .driver_features = DRIVER_GEM | DRIVER_MODESET | DRIVER_ATOMIC,
        DRM_GEM_DMA_DRIVER_OPS_WITH_DUMB_CREATE(malidp_dumb_create),
+       DRM_FBDEV_DMA_DRIVER_OPS,
 #ifdef CONFIG_DEBUG_FS
        .debugfs_init = malidp_debugfs_init,
 #endif
@@ -852,7 +854,7 @@ static int malidp_bind(struct device *dev)
        if (ret)
                goto register_fail;
 
-       drm_fbdev_dma_setup(drm, 32);
+       drm_client_setup(drm, NULL);
 
        return 0;