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:   Mon, 11 Nov 2019 21:06:55 +0100
From:   Jiri Olsa <jolsa@...hat.com>
To:     Andi Kleen <ak@...ux.intel.com>
Cc:     Andi Kleen <andi@...stfloor.org>, jolsa@...nel.org,
        acme@...nel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v5 13/13] perf stat: Use affinity for enabling/disabling
 events

On Mon, Nov 11, 2019 at 08:50:28AM -0800, Andi Kleen wrote:
> On Mon, Nov 11, 2019 at 03:04:15PM +0100, Jiri Olsa wrote:
> > On Thu, Nov 07, 2019 at 10:16:46AM -0800, Andi Kleen wrote:
> > 
> > SNIP
> > 
> > > diff --git a/tools/perf/util/evlist.c b/tools/perf/util/evlist.c
> > > index 33080f79b977..571bb102b432 100644
> > > --- a/tools/perf/util/evlist.c
> > > +++ b/tools/perf/util/evlist.c
> > > @@ -378,11 +378,28 @@ bool evsel__cpu_iter_skip(struct evsel *ev, int cpu)
> > >  void evlist__disable(struct evlist *evlist)
> > >  {
> > >  	struct evsel *pos;
> > > +	struct affinity affinity;
> > > +	int cpu, i;
> > 
> > should we have the fallback to current code in here (and below) as well?
> > also for reading/openning?
> 
> The return only happens when you're out of memory, when nothing
> will work anyways.

then let's have some assert or BUG_ON on !all_cpus
and remove the fallback code from close path

jirka

> 
> -Andi
> 
> > 
> > jirka
> > 
> > > +
> > > +	if (affinity__setup(&affinity) < 0)
> > > +		return;
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ