From patchwork Tue Nov 10 19:30:50 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Lee Jones X-Patchwork-Id: 322865 Delivered-To: patch@linaro.org Received: by 2002:a05:6e02:5ce:0:0:0:0 with SMTP id l14csp500426ils; Tue, 10 Nov 2020 11:31:48 -0800 (PST) X-Google-Smtp-Source: ABdhPJznTUDS5aUoDaY0vKR9dvvqPtbsUQ7jeVuh8jR2E9lmUwr3Uok4GhVHcNRRTn9NmqYq1ju5 X-Received: by 2002:a17:902:9347:b029:d3:b2c6:1500 with SMTP id g7-20020a1709029347b02900d3b2c61500mr2115638plp.5.1605036708269; Tue, 10 Nov 2020 11:31:48 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1605036708; cv=none; d=google.com; s=arc-20160816; b=dgzddc8DmtyyIeBqmEaeLt1ufjRrywBW1PKyK0XVcEhrtxvzeAFtZOoOeS6xcHC8iz mjigkan2GTpFCeSccfC+J9zgyxC8uXqfjuoPaTK5P/3yYc18/LbivHHKTuzQVGXTeEuG FIyFERsY6IVgBbRbscOYkog+oaj9UQ2Gs9SZ0n11aMKeFNIgN65igx+YzLscRwwetkQY ouEG0OEKit6X526jcSzJdho0AN9VS5nn1w0msP1A2XYB61u1LJVWiy8VpqbeHc8hsGzn Wehwk3+8uev2fhLqMuKPebT9tPxNHDnxdpRNncpP4cFBQfJi1dD1VyDJla4id3XccXrl PXyQ== 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=yMB7sqmeMyiCodBKDUa2bwpjWWs/ROpF9EdUh0fcA+c=; b=kXqvmme/aYw/SlTlHvSazdhm2btqYfSrkJjnHuxxGV4GFC2LatD6AG9nsTJ9ffPLjb /X0N7k6mHc/nOeQ6tL/vhNfjP9Ote3D7sn1ROYU56+Z+vhQTl5AQ76x+R/hf0ThvKfMp W8URKtBTLvETiU+90cf/RbqLbgjOywvwNR2QzpocATamFCeqB6CeO0IhQbD6OYa1/E4w xdry5LKuw1hajF1u6h1GuQ8yOnR8mbZlsjSxSoRiMWuA9g0P6o7Oy16Su1Qhrrk1JK/0 gZMjVDwDiz2XfXqBoEAnDAUFCIdXzzN9JNFwATekgaxlA5x1uVXDKcCpMuVNlWa9le0B GNIw== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=wZeGjKIo; 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 ba7si3115536plb.153.2020.11.10.11.31.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 10 Nov 2020 11:31:48 -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=wZeGjKIo; 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 39AA189C03; Tue, 10 Nov 2020 19:31: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 C422C89BF1 for ; Tue, 10 Nov 2020 19:31:27 +0000 (UTC) Received: by mail-wm1-x344.google.com with SMTP id d142so4344831wmd.4 for ; Tue, 10 Nov 2020 11:31:27 -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=WSjLdlLWJSq+5kS7GDyIv4rvxAPSqu/8nkKg/bHUTUY=; b=wZeGjKIorbPA0c0PrlnhLlnJk1itC4n0nTzOcbguHLU7XW0VZKuUzrj6ysHsa+HgNf w80Z4ZeECtO1M3dSL3w3Km0+DR8inGbS+ShcfNMffu1CCsTlpt6i1jnIPaOWiagzdSsF KB/Qkz60IzImuWaMW9jQO2moRwFqPcXUHZALrSO8+nwWhPW4OLj9h32zxfuCObMGF9Y9 BSaHqq6YxNO/GPXJY9vH4OokQ4Tsg4I5CXONrwyGmojixpVvyZaWI1FfECBoomawAlB3 ERQO8NE4MsR79/f7r0YqSxeqgu1rnXeqaWlkb7gxWwisrbJppmH2hD7OItJ6C9wbbQk0 QpiA== 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=WSjLdlLWJSq+5kS7GDyIv4rvxAPSqu/8nkKg/bHUTUY=; b=tnu+BJ+z+IHgmLt3odfn1nZmucCFodvZIt7YGi6FDj0U6RH/obHEzfJewC1M+psgLC 5IUHmaiNfi2QLSDS9WFliGB9dXMPn0hftMSM0HN8F6W/T1qgshTVnMzXFErjSx96fWZ6 6psZByX+7Pyxl9PxHylR0iz0V7BIr5HB91aoZVUSkiChi3DUpHlwxuU3R+Z6HjwxDO23 TjhyTSslYzioVJb91tREqxncV3NInK5ArFKrJZygLwN+zY691GeuMoyguwMx3vqgryi2 H4Zns74QMsB7JcgYuQzI/6Tin575liTuERZUiv9tJ1Eh7VGY2+bHrE2FKWcfryZ5YhCF KLig== X-Gm-Message-State: AOAM532nDC7QmuMFQI/ieOIOA36fPl7Ii+wGNA8KcmG1Z/yPu6Djkb8v PuxHT6oH4oqqH5+8NOy2Pg1rYw== X-Received: by 2002:a1c:448:: with SMTP id 69mr736733wme.12.1605036686390; Tue, 10 Nov 2020 11:31:26 -0800 (PST) Received: from dell.default ([91.110.221.139]) by smtp.gmail.com with ESMTPSA id 30sm17635335wrs.84.2020.11.10.11.31.25 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 10 Nov 2020 11:31:25 -0800 (PST) From: Lee Jones To: lee.jones@linaro.org Subject: [PATCH 08/30] drm/radeon/ci_dpm: Remove set but unused variable 'dpm_event_src' Date: Tue, 10 Nov 2020 19:30:50 +0000 Message-Id: <20201110193112.988999-9-lee.jones@linaro.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20201110193112.988999-1-lee.jones@linaro.org> References: <20201110193112.988999-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 , =?utf-8?q?Christian_K=C3=B6?= =?utf-8?q?nig?= Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" And the piece of code that has never been executed. Fixes the following W=1 kernel build warning(s): drivers/gpu/drm/radeon/ci_dpm.c: In function ‘ci_set_dpm_event_sources’: drivers/gpu/drm/radeon/ci_dpm.c:1369:28: warning: variable ‘dpm_event_src’ set but not used [-Wunused-but-set-variable] 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/radeon/ci_dpm.c | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/drivers/gpu/drm/radeon/ci_dpm.c b/drivers/gpu/drm/radeon/ci_dpm.c index 886e9959496fe..8324aca5fd006 100644 --- a/drivers/gpu/drm/radeon/ci_dpm.c +++ b/drivers/gpu/drm/radeon/ci_dpm.c @@ -1366,7 +1366,6 @@ static void ci_set_dpm_event_sources(struct radeon_device *rdev, u32 sources) { struct ci_power_info *pi = ci_get_pi(rdev); bool want_thermal_protection; - enum radeon_dpm_event_src dpm_event_src; u32 tmp; switch (sources) { @@ -1376,28 +1375,17 @@ static void ci_set_dpm_event_sources(struct radeon_device *rdev, u32 sources) break; case (1 << RADEON_DPM_AUTO_THROTTLE_SRC_THERMAL): want_thermal_protection = true; - dpm_event_src = RADEON_DPM_EVENT_SRC_DIGITAL; break; case (1 << RADEON_DPM_AUTO_THROTTLE_SRC_EXTERNAL): want_thermal_protection = true; - dpm_event_src = RADEON_DPM_EVENT_SRC_EXTERNAL; break; case ((1 << RADEON_DPM_AUTO_THROTTLE_SRC_EXTERNAL) | (1 << RADEON_DPM_AUTO_THROTTLE_SRC_THERMAL)): want_thermal_protection = true; - dpm_event_src = RADEON_DPM_EVENT_SRC_DIGIAL_OR_EXTERNAL; break; } if (want_thermal_protection) { -#if 0 - /* XXX: need to figure out how to handle this properly */ - tmp = RREG32_SMC(CG_THERMAL_CTRL); - tmp &= DPM_EVENT_SRC_MASK; - tmp |= DPM_EVENT_SRC(dpm_event_src); - WREG32_SMC(CG_THERMAL_CTRL, tmp); -#endif - tmp = RREG32_SMC(GENERAL_PWRMGT); if (pi->thermal_protection) tmp &= ~THERMAL_PROTECTION_DIS;