From: Daniel Vetter Subject: Re: [PATCH 03/12] drm/i915: Use adjusted_mode in HDMI 12bpc clock check Date: Mon, 2 Sep 2013 20:39:45 +0200 Message-ID: <20130902183945.GB9374@phenom.ffwll.local> References: <1378145619-22655-1-git-send-email-ville.syrjala@linux.intel.com> <1378145619-22655-4-git-send-email-ville.syrjala@linux.intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Return-path: Received: from mail-ea0-f170.google.com (mail-ea0-f170.google.com [209.85.215.170]) by gabe.freedesktop.org (Postfix) with ESMTP id 7E7B3E5C0E for ; Mon, 2 Sep 2013 11:39:31 -0700 (PDT) Received: by mail-ea0-f170.google.com with SMTP id h14so2529057eak.29 for ; Mon, 02 Sep 2013 11:39:30 -0700 (PDT) Content-Disposition: inline In-Reply-To: <1378145619-22655-4-git-send-email-ville.syrjala@linux.intel.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: intel-gfx-bounces+gcfxdi-intel-gfx=m.gmane.org@lists.freedesktop.org Errors-To: intel-gfx-bounces+gcfxdi-intel-gfx=m.gmane.org@lists.freedesktop.org To: ville.syrjala@linux.intel.com Cc: intel-gfx@lists.freedesktop.org List-Id: intel-gfx@lists.freedesktop.org On Mon, Sep 02, 2013 at 09:13:30PM +0300, ville.syrjala@linux.intel.com wro= te: > From: Ville Syrj=E4l=E4 > = > The pixel clock should come from adjusted_mode not requested_mode. > In this case the two should be the same as we don't currently > overwrite the clock in the case of HDMI. But let's make the code > safe against such things happening in the future. > = > Signed-off-by: Ville Syrj=E4l=E4 Atm only the encoder overrides the adjusted_mode at all, so I think I prefer the current code flow as clearer ... -Daniel > --- > drivers/gpu/drm/i915/intel_hdmi.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > = > diff --git a/drivers/gpu/drm/i915/intel_hdmi.c b/drivers/gpu/drm/i915/int= el_hdmi.c > index 4148cc8..48e3b32 100644 > --- a/drivers/gpu/drm/i915/intel_hdmi.c > +++ b/drivers/gpu/drm/i915/intel_hdmi.c > @@ -862,7 +862,7 @@ bool intel_hdmi_compute_config(struct intel_encoder *= encoder, > struct intel_hdmi *intel_hdmi =3D enc_to_intel_hdmi(&encoder->base); > struct drm_device *dev =3D encoder->base.dev; > struct drm_display_mode *adjusted_mode =3D &pipe_config->adjusted_mode; > - int clock_12bpc =3D pipe_config->requested_mode.clock * 3 / 2; > + int clock_12bpc =3D pipe_config->adjusted_mode.clock * 3 / 2; > int portclock_limit =3D hdmi_portclock_limit(intel_hdmi); > int desired_bpp; > = > -- = > 1.8.1.5 > = > _______________________________________________ > Intel-gfx mailing list > Intel-gfx@lists.freedesktop.org > http://lists.freedesktop.org/mailman/listinfo/intel-gfx -- = Daniel Vetter Software Engineer, Intel Corporation +41 (0) 79 365 57 48 - http://blog.ffwll.ch