From patchwork Mon Aug 29 10:33:39 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Baoyou Xie X-Patchwork-Id: 74889 Delivered-To: patch@linaro.org Received: by 10.140.29.52 with SMTP id a49csp1559662qga; Mon, 29 Aug 2016 03:34:06 -0700 (PDT) X-Received: by 10.98.202.202 with SMTP id y71mr31739115pfk.10.1472466846719; Mon, 29 Aug 2016 03:34:06 -0700 (PDT) Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id xt5si21297103pab.68.2016.08.29.03.34.06; Mon, 29 Aug 2016 03:34:06 -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 S1756791AbcH2KeC (ORCPT + 27 others); Mon, 29 Aug 2016 06:34:02 -0400 Received: from mail-pf0-f174.google.com ([209.85.192.174]:36032 "EHLO mail-pf0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756406AbcH2KeB (ORCPT ); Mon, 29 Aug 2016 06:34:01 -0400 Received: by mail-pf0-f174.google.com with SMTP id h186so50833346pfg.3 for ; Mon, 29 Aug 2016 03:34:01 -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=5moNZMRuhofvkCtIm1ZKqBVxq3I1bDN4tnDsoO9M4Hc=; b=QzZxr8+N5Q9GwyzdBUrODsWBx5cichqWke11NwLA54ziFwzzvBkyI+69FnBKRLkEDT Xe5zwYsqggZjW0XsKBpllE3dm4GDzmbcq4ZKti7F0sn3bN/CLF0ZPQPVon/d660iybxJ Vt0KwG4UP7WNmfzr0WBTiO3oaYWDkfrmgRadg= 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=5moNZMRuhofvkCtIm1ZKqBVxq3I1bDN4tnDsoO9M4Hc=; b=ZYPYjgW9FjqeMQukQCSB1gr2e5Q5I2jcSaxdqE6QxMTZt6YVbBgwJNUDtsA1pGtv54 IMmbfkoQ+aJW7ny9j7+YgyOtIkCoUlm13TcNl0Zmo4phnOX9y2DvNMSYSIRuj2ZolZ+Z 6hjE/bmU+kGkBzhLVLpJeiOVnGs21u42Sb132yYx5v+zJXoKzxvfeHUQPoSDIeJ1dvU/ diwBVc2PZddjg9mr0fFLLaAdYk8T22Xwe4j9sw9e+S+ZEKKTl3hBfYWHycx99mMdzjRm mqYRhefqZUjjOt8QdiS+QXP+AuU01Oe2leY0raTQ1ju4WxCCQCaZXd15a/d4NRZ9m/HJ 7cKQ== X-Gm-Message-State: AE9vXwOWB/SPxL/FdSHvM18s6gMghLCD82aJXZ62yP+92g6IPlu46KphgyXNp1LO1opMjBsg X-Received: by 10.98.93.25 with SMTP id r25mr31456196pfb.122.1472466840769; Mon, 29 Aug 2016 03:34:00 -0700 (PDT) Received: from localhost.localdomain ([45.56.152.36]) by smtp.gmail.com with ESMTPSA id r21sm48164321pfi.52.2016.08.29.03.33.54 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 29 Aug 2016 03:34:00 -0700 (PDT) From: Baoyou Xie To: bskeggs@redhat.com, airlied@linux.ie, Julia.Lawall@lip6.fr Cc: dri-devel@lists.freedesktop.org, nouveau@lists.freedesktop.org, linux-kernel@vger.kernel.org, arnd@linaro.org, baoyou.xie@linaro.org, xie.baoyou@zte.com.cn Subject: [PATCH] drm/nouveau/pm: mark symbols static where possible Date: Mon, 29 Aug 2016 18:33:39 +0800 Message-Id: <1472466819-15019-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 biuld kernel with W=1: drivers/gpu/drm/nouveau/nvkm/engine/pm/base.c:75:1: warning: no previous prototype for 'nvkm_perfsig_find' [-Wmissing-prototypes] drivers/gpu/drm/nouveau/nvkm/engine/pm/base.c:703:1: warning: no previous prototype for 'nvkm_perfsrc_new' [-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/nouveau/nvkm/engine/pm/base.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) -- 2.7.4 diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/pm/base.c b/drivers/gpu/drm/nouveau/nvkm/engine/pm/base.c index 8616636..dde89a4 100644 --- a/drivers/gpu/drm/nouveau/nvkm/engine/pm/base.c +++ b/drivers/gpu/drm/nouveau/nvkm/engine/pm/base.c @@ -71,7 +71,7 @@ nvkm_perfdom_find(struct nvkm_pm *pm, int di) return NULL; } -struct nvkm_perfsig * +static struct nvkm_perfsig * nvkm_perfsig_find(struct nvkm_pm *pm, u8 di, u8 si, struct nvkm_perfdom **pdom) { struct nvkm_perfdom *dom = *pdom; @@ -699,7 +699,7 @@ nvkm_pm_oclass_get(struct nvkm_oclass *oclass, int index, return 1; } -int +static int nvkm_perfsrc_new(struct nvkm_pm *pm, struct nvkm_perfsig *sig, const struct nvkm_specsrc *spec) {