Received: by 2002:a25:c593:0:0:0:0:0 with SMTP id v141csp1021076ybe; Wed, 4 Sep 2019 11:15:31 -0700 (PDT) X-Google-Smtp-Source: APXvYqzSGxvXmBqpvMSNJ8uQHYYXfVNmLnWgOaSKI4fH437VHdRQO1jVES+WkdcfFiaYxsscd9fN X-Received: by 2002:a17:902:a615:: with SMTP id u21mr40089276plq.4.1567620931676; Wed, 04 Sep 2019 11:15:31 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1567620931; cv=none; d=google.com; s=arc-20160816; b=f536Fz+YPI3xiKgl7R+it26WNCOqUkjjwlvi6EKKRHfpBzGwB2przrSJyRAdgIan1x kkG/kpFMKBK7iA+QVRpV6C+qKgL7LDF1cFP/1ZwDu2mxTbbNlRyHwXq+hdiATta3kVUa hqOoxqFoR5eokuT1YJirif+BVvaN7QuxWoKETerTjj8PSArHbS7MqaGCIQXjlLzYO22J fAVlEL5WHmRe8R3Tc6gOerIGqkA73qa+pmb1dgbIthAHKFAYC3e8y7l3e+E95XOy2PvP Td9oPk5M7v6CASGrQ4ltDG2HnV0y4GvilNSDHDyBCKLY/qfrmd1hlhCxPWMibgbC30QU SaDw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=ZxVDU8fFcTXqszhNggNEbA20tP8Otf5kKOnShczolls=; b=nHEDkU1n94wZZ+4oz/PfGKu8VUNeHcVbKPIa8r0LQdUOIeJIQS7unPdd4gJGLat8ld LGOzJT9AprbONiqlLvdrsR1TzPnvVmKREz589uSv0/FI17gplbDkm9Xn1iBAoLgN4rXD Qa4p6uQkmQGPibOeE4IKutUwiEwu8oATH1T5R+F2hf3/nLUf/25NXktohpm/+BauW/Lw ghhe71jTXcBJGiUrgYDjLR5Ia9Bt7kVMwlLR6W+Q7q7RlaOZCde+eybWMuXosfmwTWjL Udjdi0RR5cOMIjz43Fu4uinyNAAtivm9ZS1YdJGJJ/STvVEtjlwjG63WvWA7LKMJUIaD W1Qg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=CSCetijh; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f6si18241804plr.100.2019.09.04.11.15.16; Wed, 04 Sep 2019 11:15:31 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=CSCetijh; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2390358AbfIDSNu (ORCPT + 99 others); Wed, 4 Sep 2019 14:13:50 -0400 Received: from mail.kernel.org ([198.145.29.99]:58736 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2390346AbfIDSNs (ORCPT ); Wed, 4 Sep 2019 14:13:48 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 4D05A208E4; Wed, 4 Sep 2019 18:13:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1567620827; bh=CSRHk86gh5WIy5DIPkqYlXmBSEzXVknhxkEwMMZeuSM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=CSCetijhJDItUGbKzHbuImpXpkSc8oRb1Ko3yKRPifpzRlruhsb5OI11FrJodvbAm u6ps7+9LkYaFHEpsmvXecia12qOomu65596Vy7Ppoc3z/RIoZWwOvfPhXGoVrM3yyj +JWsnZet3PrhQk6QJJn1mPKN5wFwHfHm9yJjzNco= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Huang Rui , Alex Deucher , Aaron Liu Subject: [PATCH 5.2 111/143] drm/amdgpu: fix GFXOFF on Picasso and Raven2 Date: Wed, 4 Sep 2019 19:54:14 +0200 Message-Id: <20190904175318.740365280@linuxfoundation.org> X-Mailer: git-send-email 2.23.0 In-Reply-To: <20190904175314.206239922@linuxfoundation.org> References: <20190904175314.206239922@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Aaron Liu commit 41940ff50f6c347f3541163702566cd526200d98 upstream. For picasso(adev->pdev->device == 0x15d8)&raven2(adev->rev_id >= 0x8), firmware is sufficient to support gfxoff. In commit 98f58ada2d37e, for picasso&raven2, return directly and cause gfxoff disabled. Fixes: 98f58ada2d37 ("drm/amdgpu/gfx9: update pg_flags after determining if gfx off is possible") Reviewed-by: Huang Rui Reviewed-by: Alex Deucher Signed-off-by: Aaron Liu Signed-off-by: Alex Deucher Cc: stable@vger.kernel.org Signed-off-by: Greg Kroah-Hartman --- drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) --- a/drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c +++ b/drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c @@ -588,14 +588,14 @@ static void gfx_v9_0_check_if_need_gfxof case CHIP_VEGA20: break; case CHIP_RAVEN: - if (adev->rev_id >= 0x8 || adev->pdev->device == 0x15d8) - break; - if ((adev->gfx.rlc_fw_version != 106 && - adev->gfx.rlc_fw_version < 531) || - (adev->gfx.rlc_fw_version == 53815) || - (adev->gfx.rlc_feature_version < 1) || - !adev->gfx.rlc.is_rlc_v2_1) + if (!(adev->rev_id >= 0x8 || adev->pdev->device == 0x15d8) + &&((adev->gfx.rlc_fw_version != 106 && + adev->gfx.rlc_fw_version < 531) || + (adev->gfx.rlc_fw_version == 53815) || + (adev->gfx.rlc_feature_version < 1) || + !adev->gfx.rlc.is_rlc_v2_1)) adev->pm.pp_feature &= ~PP_GFXOFF_MASK; + if (adev->pm.pp_feature & PP_GFXOFF_MASK) adev->pg_flags |= AMD_PG_SUPPORT_GFX_PG | AMD_PG_SUPPORT_CP |