[<prev] [next>] [day] [month] [year] [list]
Message-Id: <20220506060410.104036-1-jiapeng.chong@linux.alibaba.com>
Date: Fri, 6 May 2022 14:04:10 +0800
From: Jiapeng Chong <jiapeng.chong@...ux.alibaba.com>
To: peterz@...radead.org
Cc: mingo@...hat.com, acme@...nel.org, mark.rutland@....com,
alexander.shishkin@...ux.intel.com, jolsa@...nel.org,
namhyung@...nel.org, tglx@...utronix.de, bp@...en8.de,
dave.hansen@...ux.intel.com, x86@...nel.org, hpa@...or.com,
linux-perf-users@...r.kernel.org, linux-kernel@...r.kernel.org,
Jiapeng Chong <jiapeng.chong@...ux.alibaba.com>,
Abaci Robot <abaci@...ux.alibaba.com>
Subject: [PATCH] x86/events: remove set but not used variable 'hwc'
Eliminate the follow clang warning:
arch/x86/events/amd/core.c:774:24: warning: variable 'hwc' set but not
used [-Wunused-but-set-variable].
Reported-by: Abaci Robot <abaci@...ux.alibaba.com>
Signed-off-by: Jiapeng Chong <jiapeng.chong@...ux.alibaba.com>
---
arch/x86/events/amd/core.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/arch/x86/events/amd/core.c b/arch/x86/events/amd/core.c
index 47ef8aee15d2..78076904daad 100644
--- a/arch/x86/events/amd/core.c
+++ b/arch/x86/events/amd/core.c
@@ -771,13 +771,11 @@ static void amd_pmu_enable_event(struct perf_event *event)
static void amd_pmu_enable_all(int added)
{
struct cpu_hw_events *cpuc = this_cpu_ptr(&cpu_hw_events);
- struct hw_perf_event *hwc;
int idx;
amd_brs_enable_all();
for (idx = 0; idx < x86_pmu.num_counters; idx++) {
- hwc = &cpuc->events[idx]->hw;
/* only activate events which are marked as active */
if (!test_bit(idx, cpuc->active_mask))
--
2.20.1.7.g153144c
Powered by blists - more mailing lists