Skip to content

Commit 0886327

Browse files
mattroperobclark
authored andcommitted
drm/exynos: Restrict plane loops to only operate on overlay planes (v2)
Ensure that existing driver loops over all planes do not change behavior when we begin adding new types of planes (primary and cursor) to the DRM plane list in future patches. v2: Switch to using drm_for_each_legacy_plane() Cc: Inki Dae <inki.dae@samsung.com> Signed-off-by: Matt Roper <matthew.d.roper@intel.com>
1 parent e27dde3 commit 0886327

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

drivers/gpu/drm/exynos/exynos_drm_crtc.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,7 @@ static void exynos_drm_crtc_disable(struct drm_crtc *crtc)
190190

191191
exynos_drm_crtc_dpms(crtc, DRM_MODE_DPMS_OFF);
192192

193-
list_for_each_entry(plane, &crtc->dev->mode_config.plane_list, head) {
193+
drm_for_each_legacy_plane(plane, &crtc->dev->mode_config.plane_list) {
194194
if (plane->crtc != crtc)
195195
continue;
196196

drivers/gpu/drm/exynos/exynos_drm_encoder.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ static void exynos_drm_encoder_disable(struct drm_encoder *encoder)
101101
exynos_drm_encoder_dpms(encoder, DRM_MODE_DPMS_OFF);
102102

103103
/* all planes connected to this encoder should be also disabled. */
104-
list_for_each_entry(plane, &dev->mode_config.plane_list, head) {
104+
drm_for_each_legacy_plane(plane, &dev->mode_config.plane_list) {
105105
if (plane->crtc == encoder->crtc)
106106
plane->funcs->disable_plane(plane);
107107
}

0 commit comments

Comments
 (0)