dri-devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Chris Wilson <chris@chris-wilson.co.uk>
To: Dave Airlie <airlied@gmail.com>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>,
	DRI Development <dri-devel@lists.freedesktop.org>
Subject: Re: [PATCH] drm/fb-helper: delay hotplug handling when partially bound
Date: Fri, 15 Jun 2012 10:32:20 +0100	[thread overview]
Message-ID: <1339752751_24743@CP5-2952> (raw)
In-Reply-To: <1339750882-23398-1-git-send-email-daniel.vetter@ffwll.ch>

On Fri, 15 Jun 2012 11:01:22 +0200, Daniel Vetter <daniel.vetter@ffwll.ch> wrote:
> Ok, this requires quite a dance to actually hit:
> 1) We plug in a 2nd screen, enable it in both X and (by vt-switching)
> in the fbcon.
> 2) We disable that screen again in with xrandr.
> 3) We vt-switch again, so that fbcon displays on the 2nd screen, but X
> on the first screen. This obviously needs a driver that doesn't switch
> off unused functions when regaining the VT.
> 3) When X controls the vt, we unplug that screen.
> 
> Now drm_fb_helper_hotplug_event we noticed that that some crtcs are
> bound, but because we still have the fbcon on the 2nd screeen we also
> have bound set. Which means the fbcon wrongly assumes it's in control
> of everything an happily disables the output on the 2nd screen, but
> enables its fb on the first screen.
> 
> Work around this issue by counting how many crtcs are bound and how
> many are bound to fbcon and assuming that when fbcon isn't bound to
> all of them, it better not touch the output configuration.
> 
> Conceptually this is the same as only restoring the fbcon output
> configuration on the driver's ->lastclose, when we're sure that no one
> else is using kms. So this should be consistent with existing kms
> drivers.
> 
> Chris has created a separate patch for the intel ddx, but I think we
> should fix this issue here regardless - the fbcon messing with the
> output config while it's not fully in control simply isn't a too
> polite behaviour.
> 
> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=50772
> Tested-by: Maxim A. Nikulin <M.A.Nikulin@gmail.com>
> Signed-Off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
-Chris

-- 
Chris Wilson, Intel Open Source Technology Centre

  reply	other threads:[~2012-06-15  9:32 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-06-15  9:01 [PATCH] drm/fb-helper: delay hotplug handling when partially bound Daniel Vetter
2012-06-15  9:32 ` Chris Wilson [this message]
2012-07-18 15:52   ` Daniel Vetter
2012-07-20  1:16     ` Dave Airlie

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=1339752751_24743@CP5-2952 \
    --to=chris@chris-wilson.co.uk \
    --cc=airlied@gmail.com \
    --cc=daniel.vetter@ffwll.ch \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox