public inbox for intel-gfx@lists.freedesktop.org
 help / color / mirror / Atom feed
From: Lyude <cpaul@redhat.com>
To: intel-gfx@lists.freedesktop.org
Subject: Solving vlv hpd issues by holding power wells?
Date: Tue, 05 Apr 2016 18:01:54 -0400	[thread overview]
Message-ID: <1459893714.28803.13.camel@redhat.com> (raw)

Hi. Currently I'm working on a bug in the i915 driver where hotplugging seems to
break if we power on the machine without any connectors attached:

https://bugzilla.redhat.com/show_bug.cgi?id=1277863

So the main cause of the issue seems to be that we're not keeping the right
power wells on for HPD to work. Booting with say, HDMI, seems to result in the
POWER_DOMAIN_AUDIO domain getting ref'd (even when it's unplugged, which seems
to be another bug in the driver I've seen on a few systems at this point), which
stops the entire display domain from being shut off and subsequently keeps hpd
working. Without anything plugged in nothing turns on any power wells and the
hpd is non-functional.

Of course my first thought was to just keep the power wells required for HPD on
for as long as we have HPD enabled in the driver. I'm not entirely sure of how
this can be done though, as disabling hotplugging interrupts is done in a
context where IRQs are disabled and as such it's impossible to grab a reference
to the power domain we need since that requires us to grab a mutex. I don't see
any pre/post uninstall hooks for this either, so just having the power well
turned on and off whenever hpd is toggled doesn't seem very easy.

On top of this, after talking to a few coworkers I'm not sure if holding a power
ref as long as hpd interrupts are enabled is the right solution either, since it
could be costly in terms of power usage. He suggested that I enable polling for
each connector in the situation where all the power domains are disabled, but
having hotplugging disabled doesn't sound right to me either.

So I guess my questions are:
   1. Should we be falling back to polling when the required power wells for
      hotplug detection aren't enabled, instead of keeping them enabled to make
      hotplugging work?
   2. If polling isn't the right way to go, what is the best way to go about
      keeping a ref to the required power wells and dropping it whenever
      hotplugging is disabled?

-- 
Cheers,
	Lyude

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

             reply	other threads:[~2016-04-05 22:01 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-04-05 22:01 Lyude [this message]
2016-04-06 11:29 ` Solving vlv hpd issues by holding power wells? Ville Syrjälä

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=1459893714.28803.13.camel@redhat.com \
    --to=cpaul@redhat.com \
    --cc=intel-gfx@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