forked from ~ljy/RK356X_SDK_RELEASE

hc
2024-05-13 9d77db3c730780c8ef5ccd4b66403ff5675cfe4e
kernel/drivers/gpu/drm/shmobile/shmob_drm_kms.c
....@@ -1,22 +1,18 @@
1
+// SPDX-License-Identifier: GPL-2.0+
12 /*
23 * shmob_drm_kms.c -- SH Mobile DRM Mode Setting
34 *
45 * Copyright (C) 2012 Renesas Electronics Corporation
56 *
67 * Laurent Pinchart (laurent.pinchart@ideasonboard.com)
7
- *
8
- * This program is free software; you can redistribute it and/or modify
9
- * it under the terms of the GNU General Public License as published by
10
- * the Free Software Foundation; either version 2 of the License, or
11
- * (at your option) any later version.
128 */
139
14
-#include <drm/drmP.h>
1510 #include <drm/drm_crtc.h>
1611 #include <drm/drm_crtc_helper.h>
1712 #include <drm/drm_fb_cma_helper.h>
1813 #include <drm/drm_gem_cma_helper.h>
1914 #include <drm/drm_gem_framebuffer_helper.h>
15
+#include <drm/drm_probe_helper.h>
2016
2117 #include "shmob_drm_crtc.h"
2218 #include "shmob_drm_drv.h"
....@@ -130,7 +126,11 @@
130126
131127 int shmob_drm_modeset_init(struct shmob_drm_device *sdev)
132128 {
133
- drm_mode_config_init(sdev->ddev);
129
+ int ret;
130
+
131
+ ret = drmm_mode_config_init(sdev->ddev);
132
+ if (ret)
133
+ return ret;
134134
135135 shmob_drm_crtc_create(sdev);
136136 shmob_drm_encoder_create(sdev);