[RFCv1 10/12] drm: convert crtc to properties/state

Ville Syrjälä ville.syrjala at linux.intel.com
Mon Oct 7 15:39:36 CEST 2013


On Sat, Oct 05, 2013 at 08:45:48PM -0400, Rob Clark wrote:
> Break the mutable state of a crtc out into a separate structure
> and use atomic properties mechanism to set crtc attributes.  This
> makes it easier to have some helpers for crtc->set_property()
> and for checking for invalid params.  The idea is that individual
> drivers can wrap the state struct in their own struct which adds
> driver specific parameters, for easy build-up of state across
> multiple set_property() calls and for easy atomic commit or roll-
> back.

I'm not sure how we're going to handle the mismatch in the behaviour of
the atomic modeset vs. the current setcrtc.

The problem is that setcrtc ignore all kinds of conflicting
crtc->connector assignments, and just overwrites whatever was there
with the latest configuration. For the atomic case we want to return an
error if there's a conflict. And another thing is the DPMS handling. The
current API forces DPMS on when you do a modeset, but for the atomic
case I want to keep things nice and clean and avoid doing such silly
things.

So I don't think we can simply convert the current modeset codepaths to
call into the atomic code. We basically need another version of the
check function, or another step that happens before .check only in the
setcrtc case which eliminates the conflicts in a way that matches the
current setcrtc behaviour.

-- 
Ville Syrjälä
Intel OTC


More information about the dri-devel mailing list