From patchwork Fri Sep 30 10:06:05 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Baoyou Xie X-Patchwork-Id: 77170 Delivered-To: patch@linaro.org Received: by 10.140.106.72 with SMTP id d66csp192754qgf; Fri, 30 Sep 2016 03:06:25 -0700 (PDT) X-Received: by 10.98.156.81 with SMTP id f78mr10205812pfe.139.1475229985708; Fri, 30 Sep 2016 03:06:25 -0700 (PDT) Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id tk9si12622356pab.52.2016.09.30.03.06.25; Fri, 30 Sep 2016 03:06:25 -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=@linaro.org; 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; dmarc=pass (p=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933483AbcI3KGX (ORCPT + 27 others); Fri, 30 Sep 2016 06:06:23 -0400 Received: from mail-pa0-f49.google.com ([209.85.220.49]:33998 "EHLO mail-pa0-f49.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933126AbcI3KGW (ORCPT ); Fri, 30 Sep 2016 06:06:22 -0400 Received: by mail-pa0-f49.google.com with SMTP id dw4so23518196pac.1 for ; Fri, 30 Sep 2016 03:06:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=HB7DDljLVHxQl6xvAIbqer1IT16rJpJpVU8hy/kE3QA=; b=WJhPoFrB9MwEWtlgHSnfXXdI6WpnJNfj2Xy70JzP22YgXaz+3PKV4ZmJtxg77ogCZR EH3JBM4CArYmpjqDaboIWDeimK3XQMiGSMeH4B4gvVpMVgmUvGDJMlqvVRaqCccwpWtN A+7hd+AkLnCn2kiDQTEe9R2MEUqKTlo5EZuQc= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=HB7DDljLVHxQl6xvAIbqer1IT16rJpJpVU8hy/kE3QA=; b=NSWs6uJqcwNUdocHga4I/puqGNdiH1rz5dtxlSrJYxnf87YSj1n1PR7d+pXkhwL32r AnA/nnW0jpXdihblm5TxQQE2fvncskBTEPcBCNbulfrFJQkgVlpzt7uAkxcCcSL5X/2p Wu+D9sPgXXH9EUuvDgDizd67HW3v2GT4BbbLfclh2U7B7G3ArnWDQqcodKElyWV9VpWd g1W+wqT2+v/feSeW6kwmnkUhdYQk3RIbySSnshjyGKlbE4tlQ/SGbl4lF+3axuMfIW8y 71brMz9SgQDOJVTCqDRof6o2veYiQvlPju4TZrb0igvKDETfr9amgQq+HREH5a5j3nkO zAKQ== X-Gm-Message-State: AA6/9RmR4Lre7Wlg4BmPnyQF8sWDq3zrmXq2klw4uX39flAuFjzeLYEJ6uQ1QnB4ZBYDLKTM X-Received: by 10.66.80.200 with SMTP id t8mr10292338pax.15.1475229981924; Fri, 30 Sep 2016 03:06:21 -0700 (PDT) Received: from localhost.localdomain ([104.237.91.182]) by smtp.gmail.com with ESMTPSA id ah5sm26599902pad.30.2016.09.30.03.06.14 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 30 Sep 2016 03:06:21 -0700 (PDT) From: Baoyou Xie To: alexander.deucher@amd.com, christian.koenig@amd.com, airlied@linux.ie, Monk.Liu@amd.com, Maruthi.Bayyavarapu@amd.com, Qingqing.Wang@amd.com, ray.huang@amd.com Cc: dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, arnd@arndb.de, baoyou.xie@linaro.org, xie.baoyou@zte.com.cn, han.fei@zte.com.cn, tang.qiang007@zte.com.cn Subject: [PATCH] drm/amdgpu: mark symbols static where possible Date: Fri, 30 Sep 2016 18:06:05 +0800 Message-Id: <1475229965-21980-1-git-send-email-baoyou.xie@linaro.org> X-Mailer: git-send-email 2.7.4 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org We get 2 warnings when building kernel with W=1: drivers/gpu/drm/amd/amdgpu/si.c:908:5: warning: no previous prototype for 'si_pciep_rreg' [-Wmissing-prototypes] drivers/gpu/drm/amd/amdgpu/si.c:921:6: warning: no previous prototype for 'si_pciep_wreg' [-Wmissing-prototypes] In fact, these functions are only used in the file in which they are declared and don't need a declaration, but can be made static. So this patch marks these functions with 'static'. Signed-off-by: Baoyou Xie --- drivers/gpu/drm/amd/amdgpu/si.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) -- 2.7.4 diff --git a/drivers/gpu/drm/amd/amdgpu/si.c b/drivers/gpu/drm/amd/amdgpu/si.c index dc9511c..bacdff8 100644 --- a/drivers/gpu/drm/amd/amdgpu/si.c +++ b/drivers/gpu/drm/amd/amdgpu/si.c @@ -905,7 +905,7 @@ static void si_pcie_wreg(struct amdgpu_device *adev, u32 reg, u32 v) spin_unlock_irqrestore(&adev->pcie_idx_lock, flags); } -u32 si_pciep_rreg(struct amdgpu_device *adev, u32 reg) +static u32 si_pciep_rreg(struct amdgpu_device *adev, u32 reg) { unsigned long flags; u32 r; @@ -918,7 +918,7 @@ u32 si_pciep_rreg(struct amdgpu_device *adev, u32 reg) return r; } -void si_pciep_wreg(struct amdgpu_device *adev, u32 reg, u32 v) +static void si_pciep_wreg(struct amdgpu_device *adev, u32 reg, u32 v) { unsigned long flags;