From patchwork Thu Sep 8 22:50:39 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Mathieu Poirier X-Patchwork-Id: 75836 Delivered-To: patch@linaro.org Received: by 10.140.106.11 with SMTP id d11csp64441qgf; Thu, 8 Sep 2016 15:51:01 -0700 (PDT) X-Received: by 10.66.147.234 with SMTP id tn10mr739539pab.144.1473375060981; Thu, 08 Sep 2016 15:51:00 -0700 (PDT) Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id uf4si403493pac.132.2016.09.08.15.51.00; Thu, 08 Sep 2016 15:51:00 -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 S1757381AbcIHWut (ORCPT + 27 others); Thu, 8 Sep 2016 18:50:49 -0400 Received: from mail-oi0-f48.google.com ([209.85.218.48]:33391 "EHLO mail-oi0-f48.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756515AbcIHWup (ORCPT ); Thu, 8 Sep 2016 18:50:45 -0400 Received: by mail-oi0-f48.google.com with SMTP id y2so98731587oie.0 for ; Thu, 08 Sep 2016 15:50:45 -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:in-reply-to:references :mime-version:content-transfer-encoding; bh=DsgsmRstql4f3PQTbN3Ainz6LRaOJ+i0Nn87PjdfVh0=; b=ac4b136aALipwRU37v2k1FLukwCkGQ4EVlkkbsI1q20UzZAWUJIusMIKw2JWUKNzLP z10Js7O8Nna+O2JM7bS1zip7StbPlCf9KE7POrMK3RrxBjxtlEW+kdvlh3NXfgxttK2C hdj8UIaDNd1vcT1bFeB4J0JlWCoQMdc57Vu7E= 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=DsgsmRstql4f3PQTbN3Ainz6LRaOJ+i0Nn87PjdfVh0=; b=QOdo6wygzTRNiRNI8paBWuRFcfXm0hSkBpbU5dMrQMdI8GhEGI8qLSIB3duOniSLu2 hAyIzcrpMAlxiHcnR/jBYNTAXXab72ps5Vh11viH8B3Qi0qe2cwrL3LuvFeCSBPSaDju pE8aloeuRhTmyxx55GEEuvEV20F/InrKkDj+rFpC1naAWiFeMuyp98iebAo4e1mAPTGL pnkpqUMAjCV+iKbfz/1p2sRiFaGQa02ylpFsGVVTXhRxo1/xA/C9E5vzXH5CrQhQ0Fw2 EjgGoY8jPsmnRrKv0iuk+4cgHmBBTmvE2dofyfAOYpZPWnjCLzMg0VcM3vHHUIJl9khP jWdA== X-Gm-Message-State: AE9vXwN6XDLYG5ymsEYjJDffKnRVBvPM5HY5uS5l/DItSZC01U9FGvY3jvTD56tk/ZbFIrJt X-Received: by 10.202.182.134 with SMTP id g128mr589318oif.148.1473375044793; Thu, 08 Sep 2016 15:50:44 -0700 (PDT) Received: from t430.cg.shawcable.net (S0106002369de4dac.cg.shawcable.net. [68.147.8.254]) by smtp.gmail.com with ESMTPSA id 194sm169598itu.4.2016.09.08.15.50.43 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 08 Sep 2016 15:50:44 -0700 (PDT) From: Mathieu Poirier To: gregkh@linuxfoundation.org Cc: linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH 2/2] coresight: tmc: mark symbols static where possible Date: Thu, 8 Sep 2016 16:50:39 -0600 Message-Id: <1473375039-5783-3-git-send-email-mathieu.poirier@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1473375039-5783-1-git-send-email-mathieu.poirier@linaro.org> References: <1473375039-5783-1-git-send-email-mathieu.poirier@linaro.org> MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Baoyou Xie We get a few warnings when building kernel with W=1: drivers/hwtracing/coresight/coresight-tmc-etr.c:23:6: warning: no previous prototype for 'tmc_etr_enable_hw' [-Wmissing-prototypes] drivers/hwtracing/coresight/coresight-tmc-etf.c:25:6: warning: no previous prototype for 'tmc_etb_enable_hw' [-Wmissing-prototypes] drivers/hwtracing/coresight/coresight-tmc.c:250:9: warning: no previous prototype for ‘trigger_cntr_show’ [-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 Signed-off-by: Mathieu Poirier --- drivers/hwtracing/coresight/coresight-tmc-etf.c | 2 +- drivers/hwtracing/coresight/coresight-tmc-etr.c | 2 +- drivers/hwtracing/coresight/coresight-tmc.c | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) -- 2.7.4 diff --git a/drivers/hwtracing/coresight/coresight-tmc-etf.c b/drivers/hwtracing/coresight/coresight-tmc-etf.c index 5fa49c4252f6..d6941ea24d8d 100644 --- a/drivers/hwtracing/coresight/coresight-tmc-etf.c +++ b/drivers/hwtracing/coresight/coresight-tmc-etf.c @@ -22,7 +22,7 @@ #include "coresight-priv.h" #include "coresight-tmc.h" -void tmc_etb_enable_hw(struct tmc_drvdata *drvdata) +static void tmc_etb_enable_hw(struct tmc_drvdata *drvdata) { CS_UNLOCK(drvdata->base); diff --git a/drivers/hwtracing/coresight/coresight-tmc-etr.c b/drivers/hwtracing/coresight/coresight-tmc-etr.c index 6d7de0309e94..886ea83c68e0 100644 --- a/drivers/hwtracing/coresight/coresight-tmc-etr.c +++ b/drivers/hwtracing/coresight/coresight-tmc-etr.c @@ -20,7 +20,7 @@ #include "coresight-priv.h" #include "coresight-tmc.h" -void tmc_etr_enable_hw(struct tmc_drvdata *drvdata) +static void tmc_etr_enable_hw(struct tmc_drvdata *drvdata) { u32 axictl; diff --git a/drivers/hwtracing/coresight/coresight-tmc.c b/drivers/hwtracing/coresight/coresight-tmc.c index a4748630f5d6..d8517d2a968c 100644 --- a/drivers/hwtracing/coresight/coresight-tmc.c +++ b/drivers/hwtracing/coresight/coresight-tmc.c @@ -247,8 +247,8 @@ static struct attribute *coresight_tmc_mgmt_attrs[] = { NULL, }; -ssize_t trigger_cntr_show(struct device *dev, - struct device_attribute *attr, char *buf) +static ssize_t trigger_cntr_show(struct device *dev, + struct device_attribute *attr, char *buf) { struct tmc_drvdata *drvdata = dev_get_drvdata(dev->parent); unsigned long val = drvdata->trigger_cntr;