From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ville =?iso-8859-1?Q?Syrj=E4l=E4?= Subject: Re: [PATCH v2] drm/i915: Add intel_dotclock_calculate() Date: Tue, 17 Sep 2013 11:16:15 +0300 Message-ID: <20130917081615.GO4531@intel.com> References: <20130913124356.GS20128@intel.com> <1379077151-7994-1-git-send-email-ville.syrjala@linux.intel.com> <87txhldnmg.fsf@intel.com> <20130916204138.GE32145@phenom.ffwll.local> Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Return-path: Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by gabe.freedesktop.org (Postfix) with ESMTP id 8F842E5EB8 for ; Tue, 17 Sep 2013 01:16:18 -0700 (PDT) Content-Disposition: inline In-Reply-To: <20130916204138.GE32145@phenom.ffwll.local> 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: Daniel Vetter Cc: intel-gfx@lists.freedesktop.org List-Id: intel-gfx@lists.freedesktop.org On Mon, Sep 16, 2013 at 10:41:38PM +0200, Daniel Vetter wrote: > On Mon, Sep 16, 2013 at 02:14:47PM +0300, Jani Nikula wrote: > > On Fri, 13 Sep 2013, ville.syrjala@linux.intel.com wrote: > > > From: Ville Syrj=E4l=E4 > > > > > > Extract the code to calculate the dotclock from the link clock and M/N > > > values into a new function from ironlake_crtc_clock_get(). > > > > > > The new function can be used to calculate the dotclock for both FDI a= nd > > > DP cases. > > > > > > Also simplify the code a bit along the way. > > > > > > v2: Don't forget about non-pch encoders in ironlake_crtc_clock_get() > > > > > > Signed-off-by: Ville Syrj=E4l=E4 > > = > > Reviewed-by: Jani Nikula > > = > > > --- > > > drivers/gpu/drm/i915/intel_display.c | 43 ++++++++++++++++++--------= ---------- > > > drivers/gpu/drm/i915/intel_drv.h | 2 ++ > > > 2 files changed, 24 insertions(+), 21 deletions(-) > > > > > > diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i= 915/intel_display.c > > > index c0ee41c..13dea9b 100644 > > > --- a/drivers/gpu/drm/i915/intel_display.c > > > +++ b/drivers/gpu/drm/i915/intel_display.c > > > @@ -7405,16 +7405,9 @@ static void i9xx_crtc_clock_get(struct intel_c= rtc *crtc, > > > pipe_config->adjusted_mode.clock =3D clock.dot; > > > } > > > = > > > -static void ironlake_crtc_clock_get(struct intel_crtc *crtc, > > > - struct intel_crtc_config *pipe_config) > > > +int intel_dotclock_calculate(int link_freq, > > > + const struct intel_link_m_n *m_n) > = > intel_dotclock_calculate is an awfully generic name for something which > computes the dotclock for an fdi/dp link ... Maybe intel_dotclock_from_m_n > instead? > = > Patch merged since I don't want to block this any longer (and maybe it > makes more sense in the end, haven't checked). Probably doesn't. It should be obvious by now that I suck at naming. -- = Ville Syrj=E4l=E4 Intel OTC