From patchwork Fri Jan 8 20:14:47 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Lee Jones X-Patchwork-Id: 359057 Delivered-To: patch@linaro.org Received: by 2002:a02:85a7:0:0:0:0:0 with SMTP id d36csp856000jai; Fri, 8 Jan 2021 12:15:59 -0800 (PST) X-Google-Smtp-Source: ABdhPJxCKmMlhIloCv1LEC9X+Kg3Ssl/Aa/kXsrGUziqsfG4nWuAkg3Q6vLmtVNCDgkv/5sW4SJC X-Received: by 2002:a63:5124:: with SMTP id f36mr8483793pgb.106.1610136958901; Fri, 08 Jan 2021 12:15:58 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1610136958; cv=none; d=google.com; s=arc-20160816; b=FqfwNZXc7nNeDtUmLnic8jpXaaoz8BUA/1K/seH0w3s/R1Tzj39mMx88tV2gcCEBJk ECwjH32EEQ01lhaRhqo8s8HYdrXaE1EqC/qBk0NxxHvYH+5kmmfwtZJZOVM485s6I1JY SGbZqiGVQJ0a1u9DOLIWqiHlj8bSHQXmDIs+by8Y+u7IHpVouPHzi5fW7iP2WXlh273I jl5Vb4oSdfmS+UMYHfM34yvpA436Ae6skD5hX5JfycFBN7Iok9hZM6SN8zCHyMmkws5P rz4USMxTZk8NrBx1mPAF5T2JWypGBz0dEOTWebCiYVEuHNyB2J9yg7Kola64rfmNcwA3 X+XA== 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=GEUKOa4LrCrO/Y0lPS6xKfsH+q4KSXPCpUud0fpCb5Y=; b=zosgCKeqiUcO/Xt5qMlE8Wq2zF9C5IV9ofIhUQlPMl3zAVI8wZrda1dcCh10XyY77G niVt8LW+gWTnaU4PMZTMoLBdrznpx7qE3aMC3i4ZRlyN0L9auWm6iUbwJGBz5AXGhDGO C1Gu2VKhkN/LveevAfI+f05aKsAnpQNxrkOjvFcw2khUM9pGkI/Gd5UmLZdqN2ylkanx XfOIRNAcglg/L8EqExHjF/Gwwn1d4HxgJDfR266wsfZFg2HtK3fOZ9F/3x6dm+0Sg6fG 0rLjNWK0vWQqj0gt+uQekZGIRzTj7MJ8aukuYqP9tbRMv6s5+tAFWjOyHM3Hkg70sVT+ OOsA== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=LF0DUdko; spf=pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 2610:10:20:722:a800:ff:fe36:1795 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. [2610:10:20:722:a800:ff:fe36:1795]) by mx.google.com with ESMTPS id w125si10038634pfb.32.2021.01.08.12.15.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 08 Jan 2021 12:15:58 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 2610:10:20:722:a800:ff:fe36:1795 as permitted sender) client-ip=2610:10:20:722:a800:ff:fe36:1795; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=LF0DUdko; spf=pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 2610:10:20:722:a800:ff:fe36:1795 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 E16506E8E2; Fri, 8 Jan 2021 20:15:52 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-wr1-x435.google.com (mail-wr1-x435.google.com [IPv6:2a00:1450:4864:20::435]) by gabe.freedesktop.org (Postfix) with ESMTPS id 3C99B6E8DC for ; Fri, 8 Jan 2021 20:15:49 +0000 (UTC) Received: by mail-wr1-x435.google.com with SMTP id m5so10133889wrx.9 for ; Fri, 08 Jan 2021 12:15:49 -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=2YbZqZMpXxFWUfLfazawHX6Ul5l98eF2j1+JdfYq+I0=; b=LF0DUdkoHdmvzblDhce37V9TWsLDe1dZxIxHP/4mt1D85NHvxbmxWWFNmay9mC0Anm +fH5Rwe0O2yf+zgF/VUlOw9Tmo7+cNs1Jtkf0U8SXp1rRQcDCzePm/cF5MzshIn253wB D96pZSPhRi7PfxFyz/KxNaBO5MYrKdpX7nWcyOoMC30hZX/Ze71Rm/b2RJfh+nF5/303 xZz/GpqBv9yIKyYzQUy5PeKKCvNiD4YcxZiGK4DUpi0C0RPPViCNf0nX3haG7pfr5JXh W9DcQGuPGcp4MDnI5hxDlQAL0z37BfAcQjLlnLkJHYIf4jEFDypcBec0Xm5SHbJeiqna Wypg== 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=2YbZqZMpXxFWUfLfazawHX6Ul5l98eF2j1+JdfYq+I0=; b=bAPN6QUUTa2WNUdLdBl8fAU50X7fwP9pJMDwRb33wmrpUv3ORa1PtP0gQbe/Ze85Ov vIH141HwNR3BssNF1nfRdmJTEly4ZbJ3CNScfRUAtQSwO2JS6iZi07MIfIpPM4J88cQf YKiabgb7pa4oU4CKswyjhBZQtT3gXNZwM50IzFIVEIc88I9nUjf3wWSYgqSq7yZtkbTu m7TM1AQjEPIa2Q7553jEtLChq4/2tf00JnaEROcHfpUcM4aEF5+9BXAaYxR0nSmvbgHa ooMb1lopIX8c2afAGUy4S/VaUjiZ8UBlw0ItUbG6eDdNO8m6rGofVdHCsmEQYKIBOkRE 53kQ== X-Gm-Message-State: AOAM530RGKDc59qNE0LwC6YxQ1P3hUQHYGSMei5LSMB4ip30ECexRAuO 0BeX0LMHTmQ3V/B/GgbcNuswag== X-Received: by 2002:adf:c18d:: with SMTP id x13mr5165454wre.128.1610136947898; Fri, 08 Jan 2021 12:15:47 -0800 (PST) Received: from dell.default ([91.110.221.229]) by smtp.gmail.com with ESMTPSA id l8sm15598671wrb.73.2021.01.08.12.15.46 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 08 Jan 2021 12:15:47 -0800 (PST) From: Lee Jones To: lee.jones@linaro.org Subject: [PATCH 30/40] drm/amd/display/dc/dce/dce_dmcu: Move 'abm_gain_stepsize' to only source file it's used in Date: Fri, 8 Jan 2021 20:14:47 +0000 Message-Id: <20210108201457.3078600-31-lee.jones@linaro.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20210108201457.3078600-1-lee.jones@linaro.org> References: <20210108201457.3078600-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: Leo Li , Mauro Rossi , linux-kernel@vger.kernel.org, amd-gfx@lists.freedesktop.org, David Airlie , dri-devel@lists.freedesktop.org, Alex Deucher , =?utf-8?q?Christian_K=C3=B6nig?= Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" And only declare it if it's to be used. Fixes the following W=1 kernel build warning(s): drivers/gpu/drm/amd/amdgpu/../display/dc/dce/dce_dmcu.h:320:23: warning: ‘abm_gain_stepsize’ defined but not used [-Wunused-const-variable=] drivers/gpu/drm/amd/amdgpu/../display/dc/dce/dce_dmcu.h:320:23: warning: ‘abm_gain_stepsize’ defined but not used [-Wunused-const-variable=] drivers/gpu/drm/amd/amdgpu/../display/dc/dce/dce_dmcu.h:320:23: warning: ‘abm_gain_stepsize’ defined but not used [-Wunused-const-variable=] drivers/gpu/drm/amd/amdgpu/../display/dc/dce/dce_dmcu.h:320:23: warning: ‘abm_gain_stepsize’ defined but not used [-Wunused-const-variable=] drivers/gpu/drm/amd/amdgpu/../display/dc/dce/dce_dmcu.h:320:23: warning: ‘abm_gain_stepsize’ defined but not used [-Wunused-const-variable=] drivers/gpu/drm/amd/amdgpu/../display/dc/dce/dce_dmcu.h:320:23: warning: ‘abm_gain_stepsize’ defined but not used [-Wunused-const-variable=] drivers/gpu/drm/amd/amdgpu/../display/dc/dce/dce_dmcu.h:320:23: warning: ‘abm_gain_stepsize’ defined but not used [-Wunused-const-variable=] Cc: Harry Wentland Cc: Leo Li Cc: Alex Deucher Cc: "Christian König" Cc: David Airlie Cc: Daniel Vetter Cc: Mauro Rossi Cc: amd-gfx@lists.freedesktop.org Cc: dri-devel@lists.freedesktop.org Signed-off-by: Lee Jones --- drivers/gpu/drm/amd/display/dc/dce/dce_dmcu.c | 4 ++++ drivers/gpu/drm/amd/display/dc/dce/dce_dmcu.h | 2 -- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/display/dc/dce/dce_dmcu.c b/drivers/gpu/drm/amd/display/dc/dce/dce_dmcu.c index fa2b47d41ee2f..30264fc151a2b 100644 --- a/drivers/gpu/drm/amd/display/dc/dce/dce_dmcu.c +++ b/drivers/gpu/drm/amd/display/dc/dce/dce_dmcu.c @@ -65,6 +65,10 @@ //Register access policy version #define mmMP0_SMN_C2PMSG_91 0x1609B +#if defined(CONFIG_DRM_AMD_DC_DCN) +static const uint32_t abm_gain_stepsize = 0x0060; +#endif + static bool dce_dmcu_init(struct dmcu *dmcu) { // Do nothing diff --git a/drivers/gpu/drm/amd/display/dc/dce/dce_dmcu.h b/drivers/gpu/drm/amd/display/dc/dce/dce_dmcu.h index 93e7f34d4775e..cefb7f5bf42cc 100644 --- a/drivers/gpu/drm/amd/display/dc/dce/dce_dmcu.h +++ b/drivers/gpu/drm/amd/display/dc/dce/dce_dmcu.h @@ -317,6 +317,4 @@ struct dmcu *dcn21_dmcu_create( void dce_dmcu_destroy(struct dmcu **dmcu); -static const uint32_t abm_gain_stepsize = 0x0060; - #endif /* _DCE_ABM_H_ */