From: Simon Farnsworth <simon.farnsworth@onelan.co.uk>
To: Keith Packard <keithp@keithp.com>
Cc: "intel-gfx@lists.freedesktop.org" <intel-gfx@lists.freedesktop.org>
Subject: Re: [PATCH] i915: Enable SDVO hotplug interrupts for HDMI and DVI
Date: Tue, 20 Sep 2011 10:38:57 +0100 [thread overview]
Message-ID: <201109201038.58129.simon.farnsworth@onelan.co.uk> (raw)
In-Reply-To: <yun8vpjhmdz.fsf@aiko.keithp.com>
On Tuesday 20 September 2011, Keith Packard <keithp@keithp.com> wrote:
> On Wed, 17 Aug 2011 10:52:21 +0100, Simon Farnsworth
<simon.farnsworth@onelan.co.uk> wrote:
> > static bool
> > intel_sdvo_multifunc_encoder(struct intel_sdvo *intel_sdvo)
> >
> > @@ -2062,7 +2053,10 @@ intel_sdvo_dvi_init(struct intel_sdvo *intel_sdvo,
> > int device)
> >
> > intel_connector = &intel_sdvo_connector->base;
> > connector = &intel_connector->base;
> >
> > - connector->polled = DRM_CONNECTOR_POLL_CONNECT |
> > DRM_CONNECTOR_POLL_DISCONNECT; + if
> > (intel_sdvo_supports_hotplug(intel_sdvo) & (1 << device))
> > + connector->polled = DRM_CONNECTOR_POLL_HPD;
> > + else
> > + connector->polled = DRM_CONNECTOR_POLL_CONNECT |
> > DRM_CONNECTOR_POLL_DISCONNECT;
> >
> > encoder->encoder_type = DRM_MODE_ENCODER_TMDS;
> > connector->connector_type = DRM_MODE_CONNECTOR_DVID;
> >
> > @@ -2587,6 +2581,11 @@ bool intel_sdvo_init(struct drm_device *dev, int
> > sdvo_reg)
> >
> > &intel_sdvo->pixel_clock_max))
> >
> > goto err;
> >
> > + if (intel_sdvo_supports_hotplug(intel_sdvo)) {
> > + intel_encoder->hot_plug = intel_sdvo_do_hotplug;
> > + intel_sdvo_set_hotplug(intel_sdvo);
> > + }
> > +
>
> This all looks quite reasonable, about the only thing I would suggest is
> that you avoid calling intel_sdvo_supports_hotplug twice in
> intel_sdvo_init and simply look at connector->polled to see if the HPD
> bit is set.
V2 patch coming up - I'll check connector->polled in intel_sdvo_init, and rely
on the call to intel_sdvo_output_setup calling a connector-specific output
function (in my case, intel_sdvo_dvi_init) that sets it correctly.
--
Simon Farnsworth
Software Engineer
ONELAN Limited
http://www.onelan.com/
prev parent reply other threads:[~2011-09-20 9:39 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-08-17 9:52 [PATCH] i915: Enable SDVO hotplug interrupts for HDMI and DVI Simon Farnsworth
2011-09-19 9:41 ` Simon Farnsworth
2011-09-19 15:03 ` Keith Packard
2011-09-19 17:23 ` Adam Jackson
2011-09-20 4:24 ` Keith Packard
2011-09-20 9:38 ` Simon Farnsworth [this message]
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=201109201038.58129.simon.farnsworth@onelan.co.uk \
--to=simon.farnsworth@onelan.co.uk \
--cc=intel-gfx@lists.freedesktop.org \
--cc=keithp@keithp.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox