Skip to content

Commit 47f571c

Browse files
author
Jyri Sarha
committed
drm/tilcdc: Initialize dummy primary plane from crtc init
Initialize dummy primary plane from crtc init. Signed-off-by: Jyri Sarha <jsarha@ti.com>
1 parent b961c48 commit 47f571c

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

drivers/gpu/drm/tilcdc/tilcdc_crtc.c

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@
2626
struct tilcdc_crtc {
2727
struct drm_crtc base;
2828

29+
struct drm_plane primary;
2930
const struct tilcdc_panel_info *info;
3031
struct drm_pending_vblank_event *event;
3132
int dpms;
@@ -782,6 +783,10 @@ struct drm_crtc *tilcdc_crtc_create(struct drm_device *dev)
782783

783784
crtc = &tilcdc_crtc->base;
784785

786+
ret = tilcdc_plane_init(dev, &tilcdc_crtc->primary);
787+
if (ret < 0)
788+
goto fail;
789+
785790
tilcdc_crtc->dpms = DRM_MODE_DPMS_OFF;
786791
init_waitqueue_head(&tilcdc_crtc->frame_done_wq);
787792

@@ -790,7 +795,11 @@ struct drm_crtc *tilcdc_crtc_create(struct drm_device *dev)
790795

791796
spin_lock_init(&tilcdc_crtc->irq_lock);
792797

793-
ret = drm_crtc_init(dev, crtc, &tilcdc_crtc_funcs);
798+
ret = drm_crtc_init_with_planes(dev, crtc,
799+
&tilcdc_crtc->primary,
800+
NULL,
801+
&tilcdc_crtc_funcs,
802+
"tilcdc crtc");
794803
if (ret < 0)
795804
goto fail;
796805

0 commit comments

Comments
 (0)