From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752550AbbIPH2a (ORCPT ); Wed, 16 Sep 2015 03:28:30 -0400 Received: from terminus.zytor.com ([198.137.202.10]:39284 "EHLO terminus.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751822AbbIPH23 (ORCPT ); Wed, 16 Sep 2015 03:28:29 -0400 Date: Wed, 16 Sep 2015 00:28:01 -0700 From: tip-bot for Namhyung Kim Message-ID: Cc: tglx@linutronix.de, a.p.zijlstra@chello.nl, acme@redhat.com, linux-kernel@vger.kernel.org, mingo@kernel.org, masami.hiramatsu.pt@hitachi.com, hpa@zytor.com, wangnan0@huawei.com, jolsa@redhat.com, namhyung@kernel.org Reply-To: linux-kernel@vger.kernel.org, mingo@kernel.org, tglx@linutronix.de, acme@redhat.com, a.p.zijlstra@chello.nl, jolsa@redhat.com, namhyung@kernel.org, hpa@zytor.com, wangnan0@huawei.com, masami.hiramatsu.pt@hitachi.com In-Reply-To: <1441852026-28974-1-git-send-email-namhyung@kernel.org> References: <1441852026-28974-1-git-send-email-namhyung@kernel.org> To: linux-tip-commits@vger.kernel.org Subject: [tip:perf/core] perf probe: Free perf_probe_event in cleanup_perf_probe_events() Git-Commit-ID: a43aac299c3abc09eff856039f5b72166b780d35 X-Mailer: tip-git-log-daemon Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=UTF-8 Content-Disposition: inline Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Commit-ID: a43aac299c3abc09eff856039f5b72166b780d35 Gitweb: http://git.kernel.org/tip/a43aac299c3abc09eff856039f5b72166b780d35 Author: Namhyung Kim AuthorDate: Thu, 10 Sep 2015 11:27:04 +0900 Committer: Arnaldo Carvalho de Melo CommitDate: Tue, 15 Sep 2015 09:48:32 -0300 perf probe: Free perf_probe_event in cleanup_perf_probe_events() The cleanup_perf_probe_events() frees all resources related to a perf probe event. However it only freed resources in trace probe events, not perf probe events. So call clear_perf_probe_event() too. Reported-by: Wang Nan Signed-off-by: Namhyung Kim Acked-by: Masami Hiramatsu Cc: Jiri Olsa Cc: Peter Zijlstra Link: http://lkml.kernel.org/r/1441852026-28974-1-git-send-email-namhyung@kernel.org Signed-off-by: Arnaldo Carvalho de Melo --- tools/perf/util/probe-event.c | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/perf/util/probe-event.c b/tools/perf/util/probe-event.c index 5964ecc..3d7d60c 100644 --- a/tools/perf/util/probe-event.c +++ b/tools/perf/util/probe-event.c @@ -2792,6 +2792,7 @@ void cleanup_perf_probe_events(struct perf_probe_event *pevs, int npevs) clear_probe_trace_event(&pevs[i].tevs[j]); zfree(&pevs[i].tevs); pevs[i].ntevs = 0; + clear_perf_probe_event(&pevs[i]); } exit_symbol_maps();