BUG: drm_crtc_helper_set_config does not work

Maarten Maathuis madman2003 at gmail.com
Fri Mar 9 00:15:22 PST 2012

On Fri, Mar 9, 2012 at 2:50 AM, Yufeng Shen <miletus at chromium.org> wrote:
> So a simple case of  disabling a CRTC and then re-enabling it.
> Disabling:
> CRTC X is originally connected to output Y
> 1. XRRSetCrtcConfig()    is called to disable CRTC  X
> 2. drm_helper_connector_dpms()   then gets called on the connector
> connected to CRTC X,
>    in the function,
>    the  connector->encoder  is set to DPMS OFF,   and the
> encoder->crtc  set to DPMS OFF
>    but the  encoder->crtc   is still CRTC X
> Re-enabling:
> 3. XRRSetCrtcConfig()    is called to to enable CRTC  X  on output Y
> 4. drm_crtc_helper_set_config ()  is now called,
> suppose   fb is not changed,  mode is not changed, encoder is not changed
> and the   encoder->crtc  is not changed,
> then we have   mode_changed == false    and  the mode is not reset
> So the CRTC X won't be connected to output Y.
> What I don't understand the code is that why  XRRSetCrtcConfig()  ends
> up only calling  drm_helper_connector_dpms()  ?
> I think it should do more than that, at least it should set the
> related  encoder->crtc = NULL
> any comments ?
> _______________________________________________
> dri-devel mailing list
> dri-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/dri-devel

As far as i know DPMS designed is a simple switch, meaning that the
mode remains active, so if you do DPMS ON it should come back. If for
some reason the driver is disconnecting the encoder from the crtc,
then it is the drivers responsibility to reconnect it when DPMS ON

But don't take my word for it, others may have more/other information.

Far away from the primal instinct, the song seems to fade away, the
river get wider between your thoughts and the things we do and say.

More information about the dri-devel mailing list