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:	Tue, 22 Jul 2014 21:22:06 +0200
From:	Jiri Olsa <jolsa@...hat.com>
To:	Adrian Hunter <adrian.hunter@...el.com>
Cc:	Arnaldo Carvalho de Melo <acme@...nel.org>,
	Peter Zijlstra <peterz@...radead.org>,
	linux-kernel@...r.kernel.org, David Ahern <dsahern@...il.com>,
	Frederic Weisbecker <fweisbec@...il.com>,
	Namhyung Kim <namhyung@...il.com>,
	Paul Mackerras <paulus@...ba.org>,
	Stephane Eranian <eranian@...gle.com>
Subject: Re: [PATCH 17/52] perf evlist: Add perf_evlist__set_tracking_event()

On Tue, Jul 22, 2014 at 04:17:26PM +0300, Adrian Hunter wrote:

SNIP

>  }
> +
> +int perf_evlist__set_tracking_event(struct perf_evlist *evlist,
> +				    struct perf_evsel *tracking_evsel)
> +{
> +	struct perf_evsel *evsel;
> +
> +	if (tracking_evsel->idx == 0)
> +		return 0;
> +
> +	if (tracking_evsel->leader->nr_members > 1)
> +		return -EINVAL;
> +
> +	list_for_each_entry(evsel, &evlist->entries, node) {
> +		if (evsel->idx < tracking_evsel->idx)
> +			evsel->idx += 1;
> +	}
> +	tracking_evsel->idx = 0;
> +
> +	return 0;
> +}

wouldnt it be better to add evsel->is_tracking bool for this?

jirka
--
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