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]
Message-ID: <20170413082815.GC4784@krava>
Date:   Thu, 13 Apr 2017 10:28:15 +0200
From:   Jiri Olsa <jolsa@...hat.com>
To:     David Carrillo-Cisneros <davidcc@...gle.com>
Cc:     linux-kernel@...r.kernel.org,
        Peter Zijlstra <peterz@...radead.org>,
        Ingo Molnar <mingo@...hat.com>,
        Arnaldo Carvalho de Melo <acme@...nel.org>,
        Alexander Shishkin <alexander.shishkin@...ux.intel.com>,
        Wang Nan <wangnan0@...wei.com>,
        Andi Kleen <ak@...ux.intel.com>,
        Adrian Hunter <adrian.hunter@...el.com>,
        Mathieu Poirier <mathieu.poirier@...aro.org>,
        Stephane Eranian <eranian@...gle.com>,
        Paul Turner <pjt@...gle.com>
Subject: Re: [PATCH] perf/stat: fix bug in handling events in error state

On Wed, Apr 12, 2017 at 11:23:01AM -0700, David Carrillo-Cisneros wrote:
> From: Stephane Eranian <eranian@...gle.com>
> 
> (This is a patch has been sitting in the Intel CQM/CMT driver series
>  for a while, despite not depend on it. Sending it now independently
>  since the series is being discarded.)
> 
> When an event is in error state, read() returns 0
> instead of sizeof() buffer. In certain modes, such
> as interval printing, ignoring the 0 return value
> may cause bogus count deltas to be computed and
> thus invalid results printed.
> 
> This patch fixes this problem by modifying read_counters()
> to mark the event as not scaled (scaled = -1) to force
> the printout routine to show <NOT COUNTED>.
> 
> Signed-off-by: Stephane Eranian <eranian@...gle.com>
> Reviewed-by: David Carrillo-Cisneros <davidcc@...gle.com>

Acked-by: Jiri Olsa <jolsa@...nel.org>

thanks,
jirka

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ