forked from ~ljy/RK356X_SDK_RELEASE

hc
2024-01-31 f70575805708cabdedea7498aaa3f710fde4d920
kernel/drivers/gpu/drm/drm_modeset_helper.c
....@@ -21,10 +21,12 @@
2121 */
2222
2323 #include <drm/drm_atomic_helper.h>
24
-#include <drm/drm_crtc_helper.h>
2524 #include <drm/drm_fb_helper.h>
25
+#include <drm/drm_fourcc.h>
2626 #include <drm/drm_modeset_helper.h>
2727 #include <drm/drm_plane_helper.h>
28
+#include <drm/drm_print.h>
29
+#include <drm/drm_probe_helper.h>
2830
2931 /**
3032 * DOC: aux kms helpers
....@@ -146,6 +148,21 @@
146148 * Initialize a CRTC object with a default helper-provided primary plane and no
147149 * cursor plane.
148150 *
151
+ * Note that we make some assumptions about hardware limitations that may not be
152
+ * true for all hardware:
153
+ *
154
+ * 1. Primary plane cannot be repositioned.
155
+ * 2. Primary plane cannot be scaled.
156
+ * 3. Primary plane must cover the entire CRTC.
157
+ * 4. Subpixel positioning is not supported.
158
+ * 5. The primary plane must always be on if the CRTC is enabled.
159
+ *
160
+ * This is purely a backwards compatibility helper for old drivers. Drivers
161
+ * should instead implement their own primary plane. Atomic drivers must do so.
162
+ * Drivers with the above hardware restriction can look into using &struct
163
+ * drm_simple_display_pipe, which encapsulates the above limitations into a nice
164
+ * interface.
165
+ *
149166 * Returns:
150167 * Zero on success, error code on failure.
151168 */