On Fri, Apr 20, 2012 at 05:59, Chris Wilson <chris at chris-wilson.co.uk>wrote: > From: Jesse Barnes <jbarnes at virtuousgeek.org> > > PCH PLLs aren't required for outputs on the CPU, so we shouldn't just > treat them as part of the pipe. > > So split the code out and manage PCH PLLs separately, allocating them > when needed or trying to re-use existing PCH PLL setups when the timings > match. > > v2: add num_pch_pll field to dev_priv (Daniel) > don't NULL the pch_pll pointer in disable or DPMS will fail (Jesse) > put register offsets in pll struct (Chris) > > v3: Decouple enable/disable of PLLs from get/put. > v4: Track temporary PLL disabling during modeset > > Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=44309 > Signed-off-by: Jesse Barnes <jbarnes at virtuousgeek.org> (up to v2) > Signed-off-by: Chris Wilson <chris at chris-wilson.co.uk> (v3+) > Chris, Jesse, I also needed the following hunk below in my tree to cope with Lynx Point. Do you want me to send it as a separate patch or you could grab it into v5? > --- > drivers/gpu/drm/i915/i915_drv.c | 4 + > drivers/gpu/drm/i915/i915_drv.h | 4 + > drivers/gpu/drm/i915/i915_reg.h | 6 +- > drivers/gpu/drm/i915/i915_suspend.c | 2 +- > drivers/gpu/drm/i915/intel_display.c | 276 > +++++++++++++++++++++++++--------- > drivers/gpu/drm/i915/intel_dp.c | 1 + > drivers/gpu/drm/i915/intel_drv.h | 13 +- > 7 files changed, 225 insertions(+), 81 deletions(-) > > diff --git a/drivers/gpu/drm/i915/i915_drv.c > b/drivers/gpu/drm/i915/i915_drv.c > index 3effcf7..355bd68 100644 > --- a/drivers/gpu/drm/i915/i915_drv.c > +++ b/drivers/gpu/drm/i915/i915_drv.c > +static int intel_pch_pll_init(struct drm_device *dev) > +{ > + drm_i915_private_t *dev_priv = dev->dev_private; > + struct intel_pch_pll *pch_plls; > + int i; > + if (dev_priv->num_pch_pll == 0) { + DRM_DEBUG_DRIVER("No PCH PLL available, skipping initialization\n"); + return 0; + } + It would work otherwise, but it would give -ENOMEM which is misleading in this case I think. -- Eugeni Dodonov <http://eugeni.dodonov.net/> -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.freedesktop.org/archives/intel-gfx/attachments/20120420/63ba6b14/attachment.htm>