From: Mika Kahola <mika.kahola@intel.com>
To: Chris Wilson <chris@chris-wilson.co.uk>
Cc: intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH v2 06/11] drm/i915: DSI pixel clock check
Date: Thu, 30 Jul 2015 13:39:04 +0300 [thread overview]
Message-ID: <1438252744.23191.14.camel@sorvi> (raw)
In-Reply-To: <20150730065241.GD6035@nuc-i3427.alporthouse.com>
On Thu, 2015-07-30 at 07:52 +0100, Chris Wilson wrote:
> On Thu, Jul 30, 2015 at 09:49:33AM +0300, Mika Kahola wrote:
> > It is possible the we request to have a mode that has
> > higher pixel clock than our HW can support. This patch
> > checks if requested pixel clock is lower than the one
> > supported by the HW. The requested mode is discarded
> > if we cannot support the requested pixel clock.
> >
> > This patch applies to DSI.
> >
> > V2:
> > - removed computation for max pixel clock
> >
> > Signed-off-by: Mika Kahola <mika.kahola@intel.com>
> > ---
> > drivers/gpu/drm/i915/intel_dsi.c | 8 ++++++++
> > 1 file changed, 8 insertions(+)
> >
> > diff --git a/drivers/gpu/drm/i915/intel_dsi.c b/drivers/gpu/drm/i915/intel_dsi.c
> > index 18dd7d7..2882978 100644
> > --- a/drivers/gpu/drm/i915/intel_dsi.c
> > +++ b/drivers/gpu/drm/i915/intel_dsi.c
> > @@ -654,6 +654,11 @@ intel_dsi_mode_valid(struct drm_connector *connector,
> > {
> > struct intel_connector *intel_connector = to_intel_connector(connector);
> > struct drm_display_mode *fixed_mode = intel_connector->panel.fixed_mode;
> > + struct intel_encoder *intel_encoder = intel_connector->encoder;
> > + struct intel_dsi *intel_dsi = enc_to_intel_dsi(&intel_encoder->base);
> > + struct drm_device *dev = intel_dsi->base.base.dev;
> > + struct drm_i915_private *dev_priv = to_i915(dev);
> > + int max_pixclk = dev_priv->max_dotclk;
>
> You only wanted i915, why all the extra steps?
> int max_pixclk = to_i915(connector->dev)->max_dotclk;
There's really no need for all these steps. All I need to extract is the
max_dotclk and I could do that shorter. This is also applicable for
other patches in the series.
-Mika-
> -Chris
>
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2015-07-30 10:36 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-07-30 6:49 [PATCH v2 00/11] Check pixel clock when setting mode Mika Kahola
2015-07-30 6:49 ` [PATCH v2 01/11] drm/i915: Store max dotclock Mika Kahola
2015-07-30 7:00 ` Chris Wilson
2015-07-30 10:27 ` Mika Kahola
2015-07-30 6:49 ` [PATCH v2 02/11] drm/i915: DisplayPort pixel clock check Mika Kahola
2015-07-30 6:49 ` [PATCH v2 03/11] drm/i915: HDMI " Mika Kahola
2015-07-30 6:54 ` Chris Wilson
2015-07-30 10:28 ` Mika Kahola
2015-07-30 6:49 ` [PATCH v2 04/11] drm/i915: LVDS " Mika Kahola
2015-07-30 6:49 ` [PATCH v2 05/11] drm/i915: SDVO " Mika Kahola
2015-07-30 6:49 ` [PATCH v2 06/11] drm/i915: DSI " Mika Kahola
2015-07-30 6:52 ` Chris Wilson
2015-07-30 10:39 ` Mika Kahola [this message]
2015-07-30 6:49 ` [PATCH v2 07/11] drm/i915: CRT " Mika Kahola
2015-07-30 6:49 ` [PATCH v2 08/11] drm/i915: TV " Mika Kahola
2015-07-30 6:49 ` [PATCH v2 09/11] drm/i915: DisplayPort-MST " Mika Kahola
2015-07-30 6:49 ` [PATCH v2 10/11] drm/i915: DVO " Mika Kahola
2015-07-30 6:49 ` [PATCH v2 11/11] drm/i915: Max DOT clock frequency to debugfs Mika Kahola
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=1438252744.23191.14.camel@sorvi \
--to=mika.kahola@intel.com \
--cc=chris@chris-wilson.co.uk \
--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