[Intel-gfx] [PATCH] drm/i915: shovel compute clock into crtc->config.dpll on ilk

Daniel Vetter daniel at ffwll.ch
Mon Apr 22 17:12:10 CEST 2013


On Mon, Apr 22, 2013 at 02:13:44PM +0300, Ville Syrjälä wrote:
> On Sat, Apr 20, 2013 at 05:19:46PM +0200, Daniel Vetter wrote:
> > This was somehow lost in the pipe_config->dpll introduction in
> > 
> > commit f47709a9502f3715cc488b788ca91cf0c142b1b1
> > Author: Daniel Vetter <daniel.vetter at ffwll.ch>
> > Date:   Thu Mar 28 10:42:02 2013 +0100
> > 
> >     drm/i915: create pipe_config->dpll for clock state
> > 
> > While at it, extract a few small helpers for common computations.
> > 
> > v2: Use the newly added helpers more thanks to Ville's trick to
> > typedef the legacy intel_clock_t as the new-world struct dpll.
> > 
> > Cc: Ville Syrjälä <ville.syrjala at linux.intel.com>
> > Signed-off-by: Daniel Vetter <daniel.vetter at ffwll.ch>
> > ---
> >  drivers/gpu/drm/i915/intel_display.c | 50 ++++++++++++++++++++++++------------
> >  1 file changed, 33 insertions(+), 17 deletions(-)
> > 
> > diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
> > index 88c19bb..63c6557 100644
> > --- a/drivers/gpu/drm/i915/intel_display.c
> > +++ b/drivers/gpu/drm/i915/intel_display.c
> > @@ -549,13 +549,18 @@ static void pineview_clock(int refclk, intel_clock_t *clock)
> >  	clock->dot = clock->vco / clock->p;
> >  }
> >  
> > +static uint32_t i9xx_dpll_compute_m(struct dpll *dpll)
> > +{
> > +	return 5 * (dpll->m1 + 2) + (dpll->m2 + 2);
> > +}
> 
> intel_find_pll_g4x_dp() has another use of this formula.

Oh, that one will die in fire in the next patch, so I didn't notice it
while doing the fixup.

> Otherwise everything looks good to me.

Still r-b? Or maybe just review the other ones, too ;-)

Cheers, Daniel
-- 
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch



More information about the Intel-gfx mailing list