kernel/patches/0132-perf-jevents-Remove-unused-variable.patch

55 lines
1.9 KiB
Diff
Raw Normal View History

From 1e5e3a66f153300977d6d74aec7fb87a47532f95 Mon Sep 17 00:00:00 2001
From: Zenghui Yu <yuzenghui@huawei.com>
Date: Wed, 15 May 2019 11:19:29 +0000
Subject: [PATCH 015/201] perf jevents: Remove unused variable
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
mainline inclusion
from mainline-v5.2-rc1
commit 8e8f515d567f9ec1d960e9fdb117d39753b7504d
category: cleanup
bugzilla: https://gitee.com/openeuler/kernel/issues/I8C0CX
Reference: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=8e8f515d567f9ec1d960e9fdb117d39753b7504d
----------------------------------------------------------------------
Address gcc warning:
pmu-events/jevents.c: In function save_arch_std_events:
pmu-events/jevents.c:417:15: warning: unused variable sb [-Wunused-variable]
struct stat *sb = data;
^~
Signed-off-by: Zenghui Yu <yuzenghui@huawei.com>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: John Garry <john.garry@huawei.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: wanghaibin.wang@huawei.com
Link: http://lkml.kernel.org/r/1557919169-23972-1-git-send-email-yuzenghui@huawei.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Signed-off-by: hongrongxuan <hongrongxuan@huawei.com>
---
tools/perf/pmu-events/jevents.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/tools/perf/pmu-events/jevents.c b/tools/perf/pmu-events/jevents.c
index af7f961b1edc..1209d0feaeb5 100644
--- a/tools/perf/pmu-events/jevents.c
+++ b/tools/perf/pmu-events/jevents.c
@@ -417,7 +417,6 @@ static int save_arch_std_events(void *data, char *name, char *event,
char *metric_name, char *metric_group)
{
struct event_struct *es;
- struct stat *sb = data;
es = malloc(sizeof(*es));
if (!es)
--
2.27.0