From patchwork Mon Mar 24 13:29:38 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rodrigo Vivi X-Patchwork-Id: 3882721 Return-Path: X-Original-To: patchwork-intel-gfx@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 67F99BF540 for ; Mon, 24 Mar 2014 13:29:56 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 9FD8C20158 for ; Mon, 24 Mar 2014 13:29:55 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id D17942013A for ; Mon, 24 Mar 2014 13:29:53 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 692506E9F6; Mon, 24 Mar 2014 06:29:53 -0700 (PDT) X-Original-To: intel-gfx@lists.freedesktop.org Delivered-To: intel-gfx@lists.freedesktop.org Received: from mail-pb0-f54.google.com (mail-pb0-f54.google.com [209.85.160.54]) by gabe.freedesktop.org (Postfix) with ESMTP id 952AE6E9F9 for ; Mon, 24 Mar 2014 06:29:51 -0700 (PDT) Received: by mail-pb0-f54.google.com with SMTP id ma3so5505475pbc.27 for ; Mon, 24 Mar 2014 06:29:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=EaoTAwgrjLFkhmK77VwTkJ2b0FfismwQ12lrvV4JK4c=; b=Sjg+1Aj0oH3KlsMMlMajok3JnENdaONgRJPu1ndms8pT+06X8rnrms88kOoTrPj67Q 8kqD2JzRZsNEMg8zTSewGYx7CcReDiODClnNzVyXcaQcmg/ODsBiEv3ksNoWiMZjKZ4o 2czHSwtDdYAJaLz5UWSTtzBYh/i8K3i0Cj9aAmT+adipHO/3kO2jcdXaG6Gq2ekQZ3/N YN2WXud3vPXY97LU8Yffgc9J0oDeYN2bue8twZbmvaZIp1Ej15PJ4cQev7Au2sQGEGTO 1iXYOA25jsZeOgek7nr3iU9C6/8Kh7zkjF4MySzKAg17kJuB/XoumG5jCkCWU0N9Im6T odTg== X-Received: by 10.68.252.165 with SMTP id zt5mr71840432pbc.17.1395667791425; Mon, 24 Mar 2014 06:29:51 -0700 (PDT) Received: from localhost (jfdmzpr02-ext.jf.intel.com. [134.134.137.71]) by mx.google.com with ESMTPSA id c7sm33306534pbt.0.2014.03.24.06.29.49 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 24 Mar 2014 06:29:50 -0700 (PDT) From: Rodrigo Vivi To: intel-gfx@lists.freedesktop.org Date: Mon, 24 Mar 2014 10:29:38 -0300 Message-Id: <1395667780-2725-2-git-send-email-rodrigo.vivi@gmail.com> X-Mailer: git-send-email 1.8.5.3 In-Reply-To: <1395667780-2725-1-git-send-email-rodrigo.vivi@gmail.com> References: <1395667780-2725-1-git-send-email-rodrigo.vivi@gmail.com> Cc: Deepak S Subject: [Intel-gfx] [PATCH 1/3] drm/i915: Bring UP Power Wells before disabling RC6. X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" X-Spam-Status: No, score=-4.6 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Deepak S We need do forcewake before Disabling RC6, This is what the BIOS expects while going into suspend. v2: updated commit message. (Daniel) Signed-off-by: Deepak S Signed-off-by: Rodrigo Vivi --- drivers/gpu/drm/i915/intel_pm.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/drivers/gpu/drm/i915/intel_pm.c b/drivers/gpu/drm/i915/intel_pm.c index fd68f93..a46a364 100644 --- a/drivers/gpu/drm/i915/intel_pm.c +++ b/drivers/gpu/drm/i915/intel_pm.c @@ -3187,8 +3187,14 @@ static void valleyview_disable_rps(struct drm_device *dev) { struct drm_i915_private *dev_priv = dev->dev_private; + /* we're doing forcewake before Disabling RC6, + * This what the BIOS expects when going into suspend */ + gen6_gt_force_wake_get(dev_priv, FORCEWAKE_ALL); + I915_WRITE(GEN6_RC_CONTROL, 0); + gen6_gt_force_wake_put(dev_priv, FORCEWAKE_ALL); + gen6_disable_rps_interrupts(dev); if (dev_priv->vlv_pctx) {