From: "Ville Syrjälä" <ville.syrjala@linux.intel.com>
To: Daniel Vetter <daniel@ffwll.ch>
Cc: rogerq@ti.com, patches@linaro.org,
dri-devel@lists.freedesktop.org, Rob Clark <rob.clark@linaro.org>
Subject: Re: [PATCH] drm: call connector->dpms(OFF) when disabling
Date: Fri, 28 Sep 2012 15:11:44 +0300 [thread overview]
Message-ID: <20120928121144.GP19732@intel.com> (raw)
In-Reply-To: <CAKMK7uGaeuUcwYkYYWQQ1WB-wHpZj0ORGL77xAKZ=jrF8WPTtA@mail.gmail.com>
On Fri, Sep 28, 2012 at 01:55:19PM +0200, Daniel Vetter wrote:
> On Fri, Sep 28, 2012 at 12:54 PM, Rob Clark <rob.clark@linaro.org> wrote:
> > Maybe it just makes sense to always do connector->dpms(OFF) before
> > unhooking the chain, rather than directly calling dpms on the
> > encoder/crtc?
>
> Well, that makes the entire (optional) ->disable stuff a bit more
> awkward. The thing imo really is that the crtc helper assume that the
> connectors do not hold any hw state, whereas you're omap driver
> violates that assumption.
>
> For the intel driver we've fixed this by doing any sink handling (e.g.
> for dp) in the encoder->dpms functions. So I think the right way for
> omap is to do the same (or conclude that the crtc helpers are a bad
> fit and ditch them). Having connectors that are special, but only in
> some of the cases imo makes squat sense for a generic helper library.
>
> >> Which is imo a clear sign that the crtc helper is a misfit for your hw and
> >> you should stop using it ;-) And adding special-case handling like this
> >> into common code, especially if it weakens the semantic concepts in the
> >> helper layer is a recipe for a maintainance disaster a few years down the
> >> road. Hence
> >
> > well, I think by the time we start adding atomic-modeset and
> > common/dsi panel framework, there might be need for a new set of
> > helpers.. but I'm not sure that the hw is quite strange enough to need
> > an omap specific set of helpers. Maybe I start w/ something in
> > omapdrm but then refactor into common functions once a few drivers are
> > converted to atomic modeset and panel framework.
>
> I see a few ways forward with the crtc helpers and atomic modeset:
> - bake the assumption into the code that drivers using the crtc
> helpers don't have any shared global resources and drop all these
> checks. This would boil down to writing a new set_config to handle
> global modeset changes (instead of changes to just one crtc).
> Obviously the current possible_encoders/possible_crtcs would still be
> checked.
> - like above, but add a driver-global ->check callback before starting
> the modeset sequence, but with the new configuration already applied
> to the kms structures.
That's essentially what my intel_atomic.c code does. Somewhat ironically,
since your modeset rework, that code is now more suited for other drivers
and I need to go and rewrite it for i915.
--
Ville Syrjälä
Intel OTC
next prev parent reply other threads:[~2012-09-28 12:11 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-09-28 7:27 [PATCH] drm: call connector->dpms(OFF) when disabling Rob Clark
2012-09-28 9:56 ` Daniel Vetter
2012-09-28 10:54 ` Rob Clark
2012-09-28 11:55 ` Daniel Vetter
2012-09-28 12:11 ` Ville Syrjälä [this message]
2012-09-28 12:19 ` Rob Clark
2012-09-28 13:36 ` Alex Deucher
2012-09-28 14:03 ` Daniel Vetter
2012-09-28 12:52 ` Alan Cox
2012-09-28 13:06 ` Rob Clark
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20120928121144.GP19732@intel.com \
--to=ville.syrjala@linux.intel.com \
--cc=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=patches@linaro.org \
--cc=rob.clark@linaro.org \
--cc=rogerq@ti.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.