All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Ville Syrjälä" <ville.syrjala@linux.intel.com>
To: Dave Airlie <airlied@gmail.com>
Cc: dri-devel <dri-devel@lists.freedesktop.org>
Subject: Re: role of crtcs in modesetting interfaces and possible abstraction away from userspace
Date: Tue, 9 Sep 2014 11:16:48 +0300	[thread overview]
Message-ID: <20140909081648.GC4193@intel.com> (raw)
In-Reply-To: <CAPM=9txgMc41SOqRDT10v1AC4UbsW_3ZF7SaQsscv57uEq81hg@mail.gmail.com>

On Tue, Sep 09, 2014 at 10:43:35AM +1000, Dave Airlie wrote:
> Hi,
> 
> So I've been attempting to hide the 30" Dell MST monitors in the
> kernel, and ran into a number of problems,
> but the major one is how to steal a crtc and get away with it.
> 
> The standard scenario I have is
> 
> CRTC 0: eDP monitor connected
> 
> hotplug 30" monitor, userspace decides to configure things as
> 
> CRTC 1: DP-4 - 30" monitor
> CRTC 2: eDP-1
> 
> But since we lack atomic it does this in two steps, so when I get the
> first modeset to set the 30" monitor up
> I go and use CRTC-2 as the secondary crtc, as CRTC-0 is in use still,
> then I have to fail the second modeset,
> and things end up with me crying.
> 
> So this led me to wonder why we expose CRTCs at all, and KMS does it
> because randr did it, but I've no idea
> why randr did it (Keith??).
> 
> >From my POV I don't think the modesetting interface needs to take
> crtcs, just connectors and modes,
> so I'm wondering going forward for atomic should we even accept crtcs
> in the interface, just a list of rectangles,
> connectors per rectangle, etc.

Not all CRTCs are created equal so the user probably wants know what
features to expect from a particular CRTC. Now, often that may have
something to do with the planes, but there are other hardware features
that we want to expose as CRTC properties. If we make all CRTCs appear
uniform to userspace the user may not know beforehand that certain
features can only be used on a subset of CRTCs. Also if the driver
would initially pick the wrong CRTC, and later the user would enable
one of those special features, we'd have to do a full modeset to switch
hardware CRTCs which would mean a nasty screen blink for the user.

So no, I don't think this is a good idea given real world hardware
constraints.

-- 
Ville Syrjälä
Intel OTC

  parent reply	other threads:[~2014-09-09  8:16 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-09  0:43 role of crtcs in modesetting interfaces and possible abstraction away from userspace Dave Airlie
2014-09-09  6:37 ` Keith Packard
2014-09-10  6:29   ` Aaron Plattner
2014-09-09  7:58 ` Dave Airlie
2014-09-09  8:16 ` Ville Syrjälä [this message]
2014-09-09 23:22   ` Rob Clark
2014-09-10  8:20     ` Ville Syrjälä
2014-09-10 13:28       ` Rob Clark
2014-09-10 16:27   ` David Herrmann
2014-09-10 17:04 ` Alex Deucher

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=20140909081648.GC4193@intel.com \
    --to=ville.syrjala@linux.intel.com \
    --cc=airlied@gmail.com \
    --cc=dri-devel@lists.freedesktop.org \
    /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.