Commit 1c71d925 authored by Marek Vasut's avatar Marek Vasut

drm: lcdif: Switch to drmm_mode_config_init

Switch from deprecated unmanaged drm_mode_config_init() to
managed drmm_mode_config_init(). No functional change.
Signed-off-by: default avatarMarek Vasut <marex@denx.de>
Acked-by: default avatarThomas Zimmermann <tzimmermann@suse.de>
Link: https://patchwork.freedesktop.org/patch/msgid/20231127212638.77688-1-marex@denx.de
parent 025ac05f
...@@ -167,7 +167,11 @@ static int lcdif_load(struct drm_device *drm) ...@@ -167,7 +167,11 @@ static int lcdif_load(struct drm_device *drm)
return ret; return ret;
/* Modeset init */ /* Modeset init */
drm_mode_config_init(drm); ret = drmm_mode_config_init(drm);
if (ret) {
dev_err(drm->dev, "Failed to initialize mode config\n");
return ret;
}
ret = lcdif_kms_init(lcdif); ret = lcdif_kms_init(lcdif);
if (ret < 0) { if (ret < 0) {
...@@ -227,7 +231,6 @@ static void lcdif_unload(struct drm_device *drm) ...@@ -227,7 +231,6 @@ static void lcdif_unload(struct drm_device *drm)
drm_crtc_vblank_off(&lcdif->crtc); drm_crtc_vblank_off(&lcdif->crtc);
drm_kms_helper_poll_fini(drm); drm_kms_helper_poll_fini(drm);
drm_mode_config_cleanup(drm);
pm_runtime_put_sync(drm->dev); pm_runtime_put_sync(drm->dev);
pm_runtime_disable(drm->dev); pm_runtime_disable(drm->dev);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment