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:	Thu, 13 Mar 2014 15:18:01 -0300
From:	Arnaldo Carvalho de Melo <acme@...stprotocols.net>
To:	Patrick Palka <patrick@...cs.ath.cx>
Cc:	Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
	Ingo Molnar <mingo@...hat.com>,
	Paul Mackerras <paulus@...ba.org>,
	Peter Zijlstra <a.p.zijlstra@...llo.nl>
Subject: Re: [PATCH] perf bench: Fix NULL pointer dereference in "perf bench
 all"

Em Thu, Mar 13, 2014 at 10:47:58AM -0400, Patrick Palka escreveu:
> On Thu, Mar 13, 2014 at 10:34 AM, Arnaldo Carvalho de Melo
> <acme@...stprotocols.net> wrote:
> > Em Wed, Mar 12, 2014 at 06:40:51PM -0400, Patrick Palka escreveu:
> >> for_each_bench() must check that the "benchmarks" field of a collection
> >> is not NULL before dereferencing it because the "all" collection in
> >> particular has a NULL "benchmarks" field (signifying that it has no
> >> benchmarks to iterate over).

> >> This fixes a NULL pointer dereference when running "perf bench all".

> > Can you please mention against which tree you're fixing things? I just
> > tried to reproduce it here on perf/urgent and this problem is not
> > reproducible by simply running:

> >   perf bench all

> > So now I'm going to try on perf/core, tip/master, etc :-\
 
> I'm fixing this on top on Linus' tree, which is currently on ac9dc67b7.
 
> Without the patch, the output of "./perf bench all" looks like:

That helps, I didn't manage to reproduce it here, I think, because I
have the numa libs installed and then a numa bench is included, and it
seems broken, which stops 'perf bench all' before it hits this problem.

I'm fixing that problem and then will process your patch.

Please add the output, possibly trimmed if long, in your next changelog
messages, that helps in more quickly seeing what is happening and
comparing with results obtained elsewhere.

Thanks,

- Arnaldo
 
> # Running sched/messaging benchmark...
> # 20 sender and receiver processes per group
> # 10 groups == 400 processes run
> 
>      Total time: 0.623 [sec]
> 
> # Running sched/pipe benchmark...
> # Executed 1000000 pipe operations between two processes
> 
>      Total time: 32.199 [sec]
> 
>       32.199419 usecs/op
>           31056 ops/sec
> 
> # Running mem/memcpy benchmark...
> # Copying 1MB Bytes ...
> 
>        1.247206 GB/Sec
>        1.268263 GB/Sec (with prefault)
> 
> # Running mem/memset benchmark...
> # Copying 1MB Bytes ...
> 
>        1.429813 GB/Sec
>        8.418642 GB/Sec (with prefault)
> 
> zsh: segmentation fault  ./perf bench all
> 
> 
> Patrick
--
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