Received: by 2002:a05:6a10:5bc5:0:0:0:0 with SMTP id os5csp225105pxb; Wed, 20 Oct 2021 20:47:22 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxQgt1L3gQFbue8+FWleIXcx7hagYWxKguQubiaCN3Xi+WUe8VhArwvEUMe1EosEPwNVeRD X-Received: by 2002:a63:bf4a:: with SMTP id i10mr2516584pgo.196.1634788042278; Wed, 20 Oct 2021 20:47:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1634788042; cv=none; d=google.com; s=arc-20160816; b=TLpsRdXJ0dTGTrXKsgdW+WkAf4/vWVfNJd4qA74k6SKpf2NZP4JUceQUaKiFVOa/D0 t7pokztmIkZHE+ZT6iMHYCIANi2zrahyGZhYouUugZ8nxaJPuEe/+JNWZf2+lFk+Mini OrYl2vvlg+zTBtsK5LcvW1qPpNElCKZ/kTTuxcfCJuVhfQA1sdXeAvmTDtr7x0BWMAhj JquJKA4KM6MlSY8OooS9mSj3U7VeC1se+QhFxEYoOc7wTxQ0SZAdZcklfvDzAlSrDRw8 EdzQvKyHkUvFa7VUsG2aRod73pKSMpxxek1mGzYyK03rM39fgGBofQK+oVODEE4C86Lr gGaA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:to:content-transfer-encoding:mime-version :message-id:date:subject:cc:from; bh=hk9n73PEvIs30lk8PbppVqma1dRFSbz2MyR488cKiEM=; b=JOERfKrHeiJPFC+iAmbXJyMQvmqN3nPJhok+pLF3Zzv4YswfFiWif8Ha+Wwkyks2f4 dAZcaqt/dziKZR3TrHYkhDeTbFv5RKY6adKmu0kiM39B7/LHi+5m/pVrfX3cfbbWRUUi EP0o/OusFJFlRnzFXiUNen4BAN+u3lL69+px4Y3acphjhPVe49l+auKUrmdrOFjUqaLv ngLi08+qm6l6SxxZwcZ22L9gRK/JoKL6PvUmUodt+P4R9tTvhmCemDVQSh/batQ0Arnt TXjeM5cbf3jVg4fQCZkB8XqBsHa7H4ivSm/o/nbgkw+Q+cYWU1RcKSHxmZE4kKpyVgTD YIhw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=huawei.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id a16si6048251pfv.95.2021.10.20.20.47.08; Wed, 20 Oct 2021 20:47:22 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=huawei.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230507AbhJUDrT (ORCPT + 99 others); Wed, 20 Oct 2021 23:47:19 -0400 Received: from szxga02-in.huawei.com ([45.249.212.188]:14836 "EHLO szxga02-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230453AbhJUDrT (ORCPT ); Wed, 20 Oct 2021 23:47:19 -0400 Received: from dggemv711-chm.china.huawei.com (unknown [172.30.72.53]) by szxga02-in.huawei.com (SkyGuard) with ESMTP id 4HZYC941jLz90MY; Thu, 21 Oct 2021 11:40:05 +0800 (CST) Received: from dggpemm500015.china.huawei.com (7.185.36.181) by dggemv711-chm.china.huawei.com (10.1.198.66) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.15; Thu, 21 Oct 2021 11:45:01 +0800 Received: from huawei.com (10.175.103.91) by dggpemm500015.china.huawei.com (7.185.36.181) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.15; Thu, 21 Oct 2021 11:45:01 +0800 From: Wang ShaoBo CC: , , , , , Subject: [PATCH] trace/hwlat: Make internal symbol static Date: Thu, 21 Oct 2021 11:52:25 +0800 Message-ID: <20211021035225.1050685-1-bobo.shaobowang@huawei.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Content-Transfer-Encoding: 7BIT Content-Type: text/plain; charset=US-ASCII X-Originating-IP: [10.175.103.91] X-ClientProxiedBy: dggems706-chm.china.huawei.com (10.3.19.183) To dggpemm500015.china.huawei.com (7.185.36.181) X-CFilter-Loop: Reflected To: unlisted-recipients:; (no To-header on input) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The sparse tool complains as follows: kernel/trace/trace_hwlat.c:82:27: warning: symbol 'hwlat_single_cpu_data' was not declared. Should it be static? kernel/trace/trace_hwlat.c:83:1: warning: symbol '__pcpu_scope_hwlat_per_cpu_data' was not declared. Should it be static? This symbol is not used outside of trace_hwlat.c, so this commit marks it static. Signed-off-by: Wang ShaoBo --- kernel/trace/trace_hwlat.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/kernel/trace/trace_hwlat.c b/kernel/trace/trace_hwlat.c index 1b83d75eb103..263dde9016e4 100644 --- a/kernel/trace/trace_hwlat.c +++ b/kernel/trace/trace_hwlat.c @@ -79,8 +79,8 @@ struct hwlat_kthread_data { int nmi_cpu; }; -struct hwlat_kthread_data hwlat_single_cpu_data; -DEFINE_PER_CPU(struct hwlat_kthread_data, hwlat_per_cpu_data); +static struct hwlat_kthread_data hwlat_single_cpu_data; +static DEFINE_PER_CPU(struct hwlat_kthread_data, hwlat_per_cpu_data); /* Tells NMIs to call back to the hwlat tracer to record timestamps */ bool trace_hwlat_callback_enabled; -- 2.25.1