lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 9 Sep 2015 21:42:08 +0000
From:	"Liang, Kan" <kan.liang@...el.com>
To:	Arnaldo Carvalho de Melo <acme@...nel.org>
CC:	Ingo Molnar <mingo@...nel.org>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	Arnaldo Carvalho de Melo <acme@...hat.com>,
	"Hunter, Adrian" <adrian.hunter@...el.com>,
	Borislav Petkov <bp@...e.de>, David Ahern <dsahern@...il.com>,
	Frederic Weisbecker <fweisbec@...il.com>,
	Jiri Olsa <jolsa@...nel.org>,
	Namhyung Kim <namhyung@...nel.org>,
	"Stephane Eranian" <eranian@...gle.com>,
	Wang Nan <wangnan0@...wei.com>
Subject: RE: [PATCH 11/13] Revert "perf evsel: Add a backpointer to the
 evlist a evsel is in"



> 
> From: Arnaldo Carvalho de Melo <acme@...hat.com>
> 
> This reverts commit d49e4695077278ee3016cd242967de23072ec331.
> 
> We don't need it, using machine->env seems to be enough.

The patchset to dump freq per sample need commit d49e469507.
It also needs commit 2c07144dfc which is revert by PATCH 13.
https://lkml.org/lkml/2015/9/8/758

Otherwise, we have to pass evlist and machine through dump_sample.

> 
> Cc: Adrian Hunter <adrian.hunter@...el.com>
> Cc: Borislav Petkov <bp@...e.de>
> Cc: David Ahern <dsahern@...il.com>
> Cc: Frederic Weisbecker <fweisbec@...il.com>
> Cc: Jiri Olsa <jolsa@...nel.org>
> Cc: Kan Liang <kan.liang@...el.com>
> Cc: Namhyung Kim <namhyung@...nel.org>
> Cc: Stephane Eranian <eranian@...gle.com>
> Cc: Wang Nan <wangnan0@...wei.com>
> Signed-off-by: Arnaldo Carvalho de Melo <acme@...hat.com>
> ---
>  tools/perf/util/evlist.c | 2 --
>  tools/perf/util/evsel.c  | 2 --
>  tools/perf/util/evsel.h  | 4 ----
>  3 files changed, 8 deletions(-)
> 
> diff --git a/tools/perf/util/evlist.c b/tools/perf/util/evlist.c index
> d51a5200c8af..09b4ec221dda 100644
> --- a/tools/perf/util/evlist.c
> +++ b/tools/perf/util/evlist.c
> @@ -98,7 +98,6 @@ static void perf_evlist__purge(struct perf_evlist
> *evlist)
> 
>  	evlist__for_each_safe(evlist, n, pos) {
>  		list_del_init(&pos->node);
> -		pos->evlist = NULL;
>  		perf_evsel__delete(pos);
>  	}
> 
> @@ -126,7 +125,6 @@ void perf_evlist__delete(struct perf_evlist *evlist)
> 
>  void perf_evlist__add(struct perf_evlist *evlist, struct perf_evsel *entry)
> {
> -	entry->evlist = evlist;
>  	list_add_tail(&entry->node, &evlist->entries);
>  	entry->idx = evlist->nr_entries;
>  	entry->tracking = !entry->idx;
> diff --git a/tools/perf/util/evsel.c b/tools/perf/util/evsel.c index
> 771ade4d5966..8f4d45002461 100644
> --- a/tools/perf/util/evsel.c
> +++ b/tools/perf/util/evsel.c
> @@ -206,7 +206,6 @@ void perf_evsel__init(struct perf_evsel *evsel,
>  	evsel->leader	   = evsel;
>  	evsel->unit	   = "";
>  	evsel->scale	   = 1.0;
> -	evsel->evlist	   = NULL;
>  	INIT_LIST_HEAD(&evsel->node);
>  	INIT_LIST_HEAD(&evsel->config_terms);
>  	perf_evsel__object.init(evsel);
> @@ -1027,7 +1026,6 @@ void perf_evsel__close_fd(struct perf_evsel
> *evsel, int ncpus, int nthreads)  void perf_evsel__exit(struct perf_evsel
> *evsel)  {
>  	assert(list_empty(&evsel->node));
> -	assert(evsel->evlist == NULL);
>  	perf_evsel__free_fd(evsel);
>  	perf_evsel__free_id(evsel);
>  	perf_evsel__free_config_terms(evsel);
> diff --git a/tools/perf/util/evsel.h b/tools/perf/util/evsel.h index
> 298e6bbca200..93ac6b128149 100644
> --- a/tools/perf/util/evsel.h
> +++ b/tools/perf/util/evsel.h
> @@ -60,9 +60,6 @@ struct perf_evsel_config_term {
> 
>  /** struct perf_evsel - event selector
>   *
> - * @evlist - evlist this evsel is in, if it is in one.
> - * @node - To insert it into evlist->entries or in other list_heads, say in
> - *         the event parsing routines.
>   * @name - Can be set to retain the original event name passed by the
> user,
>   *         so that when showing results in tools such as 'perf stat', we
>   *         show the name used, not some alias.
> @@ -76,7 +73,6 @@ struct perf_evsel_config_term {
>   */
>  struct perf_evsel {
>  	struct list_head	node;
> -	struct perf_evlist	*evlist;
>  	struct perf_event_attr	attr;
>  	char			*filter;
>  	struct xyarray		*fd;
> --
> 2.1.0

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ