]> git.baikalelectronics.ru Git - kernel.git/commit
drm/omap: fix enabling/disabling of video pipeline
authorTomi Valkeinen <tomi.valkeinen@ti.com>
Thu, 3 Apr 2014 10:11:54 +0000 (13:11 +0300)
committerTomi Valkeinen <tomi.valkeinen@ti.com>
Mon, 14 Apr 2014 09:34:14 +0000 (12:34 +0300)
commit3301e28b419a95d662215805b4c27a457fe12e6a
treeb14ae7f139afb20cb7ff4d7daf7b2e750bc87453
parente0f87b94813a3cbdcd9c7bd29026b2c37b9c4cc4
drm/omap: fix enabling/disabling of video pipeline

At the moment the omap_crtc_pre_apply() handles the enabling, disabling
and configuring of encoders and panels separately from the CRTC (i.e.
the overlay manager).

However, this doesn't work correctly. The encoder driver has to be in
control of its video input (i.e. the crtc) for correct operation.

This problem causes bugs with (at least) HDMI: the HDMI encoder supplies
pixel clock for DISPC, and DISPC supplies video stream for HDMI. The
current code first enables the HDMI encoder, and CRTC after that.
However, the encoder expects the video stream to start during the
encoder's enable, and if it doesn't, there will be sync lost errors.

The encoder enables its video source by calling src->enable(), and this
call goes to omapdrm (omap_crtc_enable), but omapdrm doesn't do anything
in that function. Similarly for disable, which goes to
omap_crtc_disable().

This patch moves the code to setup and enable/disable the crtc to
omap_crtc_enable. and omap_crtc_disable().

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Reviewed-by: Rob Clark <robdclark@gmail.com>
drivers/gpu/drm/omapdrm/omap_crtc.c