From mboxrd@z Thu Jan 1 00:00:00 1970 From: Daniel Vetter Subject: Re: [PATCH v2] drm/i915: Bring GPU Freq to min while suspending. Date: Wed, 18 Jun 2014 00:17:23 +0200 Message-ID: <20140617221723.GX5821@phenom.ffwll.local> References: <1403049653-31480-1-git-send-email-deepak.s@linux.intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail-we0-f170.google.com (mail-we0-f170.google.com [74.125.82.170]) by gabe.freedesktop.org (Postfix) with ESMTP id 3ACF36E09D for ; Tue, 17 Jun 2014 15:17:31 -0700 (PDT) Received: by mail-we0-f170.google.com with SMTP id w61so2742wes.1 for ; Tue, 17 Jun 2014 15:17:30 -0700 (PDT) Content-Disposition: inline In-Reply-To: <1403049653-31480-1-git-send-email-deepak.s@linux.intel.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" To: deepak.s@linux.intel.com Cc: intel-gfx@lists.freedesktop.org List-Id: intel-gfx@lists.freedesktop.org On Wed, Jun 18, 2014 at 05:30:53AM +0530, deepak.s@linux.intel.com wrote: > From: Deepak S > > We might be leaving the GPU Frequency (and thus vnn) high during the suspend. > Flush the delayed work queue should take care of this. > > v2: Fixed typo in commit message (Deepak) > > Signed-off-by: Deepak S > --- > drivers/gpu/drm/i915/i915_gem.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/gpu/drm/i915/i915_gem.c b/drivers/gpu/drm/i915/i915_gem.c > index 7f643db..8d5ae82 100644 > --- a/drivers/gpu/drm/i915/i915_gem.c > +++ b/drivers/gpu/drm/i915/i915_gem.c > @@ -4541,7 +4541,7 @@ i915_gem_suspend(struct drm_device *dev) > > del_timer_sync(&dev_priv->gpu_error.hangcheck_timer); > cancel_delayed_work_sync(&dev_priv->mm.retire_work); > - cancel_delayed_work_sync(&dev_priv->mm.idle_work); > + flush_delayed_work(&dev_priv->mm.idle_work); Shouldn't we do that in suspend_gt_powersave instead? Also if we cancel the retire work the idle work won't necessarily get armed and we might miss the window. Just forcing the gt to the lowest freq in suspend_gt_powersave should be more reliable. -Daniel -- Daniel Vetter Software Engineer, Intel Corporation +41 (0) 79 365 57 48 - http://blog.ffwll.ch