From patchwork Thu Nov 26 13:42:31 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Lee Jones X-Patchwork-Id: 333008 Delivered-To: patch@linaro.org Received: by 2002:a17:906:4755:0:0:0:0 with SMTP id j21csp156218ejs; Thu, 26 Nov 2020 05:43:57 -0800 (PST) X-Google-Smtp-Source: ABdhPJz7vHchuyeWovqiHtBce+/vNu8VXCZd0/SEWUv7AerxFeuw/WmQDkMEb9A08P4TmCgPsIR1 X-Received: by 2002:a17:90b:88b:: with SMTP id bj11mr3786425pjb.229.1606398237488; Thu, 26 Nov 2020 05:43:57 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1606398237; cv=none; d=google.com; s=arc-20160816; b=GPH3uqA5TkYvuhEjzoxT/k0CtVn4pjzv4kSeuAJTdzc8NzxPS/aTMDrPvXWaMkCVor T0PMNTl4d75TWqIk9COM5qwUR0c3uV1veKcAc8Rxj9/IFl9Ib/l8XoXWKEjTdIermLgK gCkazj01wwR02TIN+whCSBPYEa5dmpqjz1hvifBDhzs+zGGi/2jL343sAt+KAJH/Fmnf X674yDAuwC5I6t20pmzsakYbGC8MolnIntKyj72ttJmVyTPBZ/TqYETHyi4H20+p7KIb r2QbmEPjH+Pmq2R2TAVNspeFICA8cKvJTAlocIVfpw4SIbJ8D3AHpcUdUsq/GiJjFh7H tdNQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:cc:list-subscribe :list-help:list-post:list-archive:list-unsubscribe:list-id :precedence:mime-version:references:in-reply-to:message-id:date :subject:to:from:dkim-signature:delivered-to; bh=+Pm900iIykQ5Og2NtsEdXo1Z9W3YHA8c+hfk9FoCrQQ=; b=kbM6hu+EXeZqnAoz/xXLzJAI9AYn/JRpGI4v28JEXktHz7/kZdiPpesJusjIn2BwdN rG3oj7GQp4NAJqIps1LFxigJukvoZYlafiY70LTbzApm+Azn8v808zs95GkCC1cikwL5 DP1QctgkRYLl4KqNXtr6D4gu9Q4uCWKrrOTXBlc8fJBAdZBUlppGLPn9gdpf/bFkIPx7 nzIB2/R7Q6JH95c8eJjIAXQ5faFaegShOqwjI8kdDRRzGqmaGiaWLwuUfRwz3p6mHV8a m57EUfgC+jkBU3d17X4EDarNWzn6U1g0iZWjKn1vu/ouG1XWnN6md9yra8nKCTIBoh+4 WJFg== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=KS9rezDP; spf=pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 131.252.210.177 as permitted sender) smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from gabe.freedesktop.org (gabe.freedesktop.org. [131.252.210.177]) by mx.google.com with ESMTPS id z22si5581664pfk.277.2020.11.26.05.43.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 26 Nov 2020 05:43:57 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 131.252.210.177 as permitted sender) client-ip=131.252.210.177; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=KS9rezDP; spf=pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 131.252.210.177 as permitted sender) smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 8DBE96E984; Thu, 26 Nov 2020 13:43:35 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-wm1-x344.google.com (mail-wm1-x344.google.com [IPv6:2a00:1450:4864:20::344]) by gabe.freedesktop.org (Postfix) with ESMTPS id 2A4C36E96C for ; Thu, 26 Nov 2020 13:43:33 +0000 (UTC) Received: by mail-wm1-x344.google.com with SMTP id c198so2212134wmd.0 for ; Thu, 26 Nov 2020 05:43:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=aby0rkFSc8Z8n2GfbnJMGwcXmsbKBW3Qw486TCADV5Q=; b=KS9rezDPHF4lJPHeXTEzQv//j6gJAj01Y9abTsVhXJGUNfMvvq61u2fvx8NkTyvSvz 5PNXYeVNUVn/eLVZLLaGtU2hWozWLb2zxKeozOenCwJcRMfeqPsx6RsCqIStffOPrn8w UjJ/fbBDLbG5uyFaoyIx/uuero3LTMuoZbifOmkIcYB78DPAogQWaLFs9/+UyaXlpJFk Ywd72NT2ORdTOevBH1ID3BhUV2FDC6zfpZM4fqGkwaGyZUqGZ+62+vzUOqS6IcxppsWG JNFRR34u0WMmm40gsVuNbO6hOjagpyiV0yCSi1OPu4gmH9jbFk2JMSuv2mBCD9zK0Cc5 qaeA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=aby0rkFSc8Z8n2GfbnJMGwcXmsbKBW3Qw486TCADV5Q=; b=PeoMyaXOeo45WE71WtIM+jg+iRLzjkEI0veSzpa4spo87mNTVlAo8vSuAwfUng/r0E p7ySV5iKkfirYsLkOp+o2scUsn3g+gbetelwuX0cN+RtDZgOjowJldFFjE7ue9vZaAid g7rSxYUPp6ux8PCO0QLchtfErsSW4gEsLNww4UXKGVxYeHV/JyUtnM7HiKdX8nsqBp3D kHFhF2LrC836wDslNKe8lRoJK3TmMELG97jK8klY/VVUUXlKsCSY+eme4jkROyZh5WJD rFQtENQ4OTb9lDko482YDwL3oVZg3zXvx2CUBMReCR+IwjF59Ukq4Phus8Y2z4z9cVEw z5cg== X-Gm-Message-State: AOAM533gE/U40QmIIyfa1kBqZwL+1RAXIi+V2HoZIQzayK3v55ewB0IZ dtJ7A17xaEt10qSbAiUlOw2zfw== X-Received: by 2002:a1c:9949:: with SMTP id b70mr3411531wme.85.1606398211846; Thu, 26 Nov 2020 05:43:31 -0800 (PST) Received: from dell.default ([91.110.221.235]) by smtp.gmail.com with ESMTPSA id k205sm9275738wmk.4.2020.11.26.05.43.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 26 Nov 2020 05:43:31 -0800 (PST) From: Lee Jones To: lee.jones@linaro.org Subject: [PATCH 31/40] drm/amd/pm/powerplay/kv_dpm: Remove unused variable 'ret' Date: Thu, 26 Nov 2020 13:42:31 +0000 Message-Id: <20201126134240.3214176-32-lee.jones@linaro.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20201126134240.3214176-1-lee.jones@linaro.org> References: <20201126134240.3214176-1-lee.jones@linaro.org> MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: David Airlie , linux-kernel@vger.kernel.org, amd-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org, Alex Deucher , Evan Quan , =?utf-8?q?Christian_K=C3=B6nig?= Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Fixes the following W=1 kernel build warning(s): drivers/gpu/drm/amd/amdgpu/../pm/powerplay/kv_dpm.c: In function ‘kv_dpm_powergate_uvd’: drivers/gpu/drm/amd/amdgpu/../pm/powerplay/kv_dpm.c:1678:6: warning: variable ‘ret’ set but not used [-Wunused-but-set-variable] drivers/gpu/drm/amd/amdgpu/../pm/powerplay/kv_dpm.c: In function ‘kv_dpm_powergate_vce’: drivers/gpu/drm/amd/amdgpu/../pm/powerplay/kv_dpm.c:1706:6: warning: variable ‘ret’ set but not used [-Wunused-but-set-variable] Cc: Evan Quan Cc: Alex Deucher Cc: "Christian König" Cc: David Airlie Cc: Daniel Vetter Cc: amd-gfx@lists.freedesktop.org Cc: dri-devel@lists.freedesktop.org Signed-off-by: Lee Jones --- drivers/gpu/drm/amd/pm/powerplay/kv_dpm.c | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) diff --git a/drivers/gpu/drm/amd/pm/powerplay/kv_dpm.c b/drivers/gpu/drm/amd/pm/powerplay/kv_dpm.c index 4b3faaccecb94..66daabebee358 100644 --- a/drivers/gpu/drm/amd/pm/powerplay/kv_dpm.c +++ b/drivers/gpu/drm/amd/pm/powerplay/kv_dpm.c @@ -1675,14 +1675,13 @@ static void kv_dpm_powergate_uvd(void *handle, bool gate) { struct amdgpu_device *adev = (struct amdgpu_device *)handle; struct kv_power_info *pi = kv_get_pi(adev); - int ret; pi->uvd_power_gated = gate; if (gate) { /* stop the UVD block */ - ret = amdgpu_device_ip_set_powergating_state(adev, AMD_IP_BLOCK_TYPE_UVD, - AMD_PG_STATE_GATE); + amdgpu_device_ip_set_powergating_state(adev, AMD_IP_BLOCK_TYPE_UVD, + AMD_PG_STATE_GATE); kv_update_uvd_dpm(adev, gate); if (pi->caps_uvd_pg) /* power off the UVD block */ @@ -1694,8 +1693,8 @@ static void kv_dpm_powergate_uvd(void *handle, bool gate) /* re-init the UVD block */ kv_update_uvd_dpm(adev, gate); - ret = amdgpu_device_ip_set_powergating_state(adev, AMD_IP_BLOCK_TYPE_UVD, - AMD_PG_STATE_UNGATE); + amdgpu_device_ip_set_powergating_state(adev, AMD_IP_BLOCK_TYPE_UVD, + AMD_PG_STATE_UNGATE); } } @@ -1703,14 +1702,13 @@ static void kv_dpm_powergate_vce(void *handle, bool gate) { struct amdgpu_device *adev = (struct amdgpu_device *)handle; struct kv_power_info *pi = kv_get_pi(adev); - int ret; pi->vce_power_gated = gate; if (gate) { /* stop the VCE block */ - ret = amdgpu_device_ip_set_powergating_state(adev, AMD_IP_BLOCK_TYPE_VCE, - AMD_PG_STATE_GATE); + amdgpu_device_ip_set_powergating_state(adev, AMD_IP_BLOCK_TYPE_VCE, + AMD_PG_STATE_GATE); kv_enable_vce_dpm(adev, false); if (pi->caps_vce_pg) /* power off the VCE block */ amdgpu_kv_notify_message_to_smu(adev, PPSMC_MSG_VCEPowerOFF); @@ -1719,8 +1717,8 @@ static void kv_dpm_powergate_vce(void *handle, bool gate) amdgpu_kv_notify_message_to_smu(adev, PPSMC_MSG_VCEPowerON); kv_enable_vce_dpm(adev, true); /* re-init the VCE block */ - ret = amdgpu_device_ip_set_powergating_state(adev, AMD_IP_BLOCK_TYPE_VCE, - AMD_PG_STATE_UNGATE); + amdgpu_device_ip_set_powergating_state(adev, AMD_IP_BLOCK_TYPE_VCE, + AMD_PG_STATE_UNGATE); } }