[PATCH 1/2] drm/tilcdc: use drm_fbdev_generic_setup
Jyri Sarha
jsarha at ti.com
Fri Feb 15 08:13:15 UTC 2019
Calling drm_fbdev_cma_fini() after drm_dev_unregister() started to
cause a crash when unloading tilcdc some time between 4.14 and
4.19. Instead of changing the unload order it looks like using
drm_fbdev_generic_setup() is the direction to go.
Signed-off-by: Jyri Sarha <jsarha at ti.com>
---
drivers/gpu/drm/tilcdc/tilcdc_drv.c | 9 +++------
1 file changed, 3 insertions(+), 6 deletions(-)
diff --git a/drivers/gpu/drm/tilcdc/tilcdc_drv.c b/drivers/gpu/drm/tilcdc/tilcdc_drv.c
index 33e533268488..6d84491f2a4f 100644
--- a/drivers/gpu/drm/tilcdc/tilcdc_drv.c
+++ b/drivers/gpu/drm/tilcdc/tilcdc_drv.c
@@ -192,8 +192,6 @@ static void tilcdc_fini(struct drm_device *dev)
drm_kms_helper_poll_fini(dev);
- drm_fb_cma_fbdev_fini(dev);
-
drm_irq_uninstall(dev);
drm_mode_config_cleanup(dev);
tilcdc_remove_external_device(dev);
@@ -396,10 +394,6 @@ static int tilcdc_init(struct drm_driver *ddrv, struct device *dev)
drm_mode_config_reset(ddev);
- ret = drm_fb_cma_fbdev_init(ddev, bpp, 0);
- if (ret)
- goto init_failed;
-
drm_kms_helper_poll_init(ddev);
ret = drm_dev_register(ddev, 0);
@@ -407,6 +401,9 @@ static int tilcdc_init(struct drm_driver *ddrv, struct device *dev)
goto init_failed;
priv->is_registered = true;
+
+ drm_fbdev_generic_setup(ddev, bpp);
+
return 0;
init_failed:
--
Texas Instruments Finland Oy, Porkkalankatu 22, 00180 Helsinki. Y-tunnus/Business ID: 0615521-4. Kotipaikka/Domicile: Helsinki
More information about the dri-devel
mailing list