mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 10:41:38 -04:00
perf pmu: fix alias->snapshot missing initialization bug
This patch fixes a bug in __perf_pmu__new_alias() whereby the alias->snapshot field was not initialized to false. This led to random alias->snapshot value for an alias and was breaking some measurements such as: $ perf stat -a -e uncore_imc/data_reads/ -I 1000 sleep 100 Because the event ended up being treated as snapshot mode, when it is not. Signed-off-by: Stephane Eranian <[email protected]> Cc: Andi Kleen <[email protected]> Cc: Jiri Olsa <[email protected]> Cc: Kan Liang <[email protected]> Cc: Peter Zijlstra <[email protected]> Link: http://lkml.kernel.org/r/[email protected] Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
This commit is contained in:
parent
b8a1962d17
commit
84530920de
1 changed files with 1 additions and 0 deletions
|
|
@ -220,6 +220,7 @@ static int __perf_pmu__new_alias(struct list_head *list, char *dir, char *name,
|
|||
alias->scale = 1.0;
|
||||
alias->unit[0] = '\0';
|
||||
alias->per_pkg = false;
|
||||
alias->snapshot = false;
|
||||
|
||||
ret = parse_events_terms(&alias->terms, val);
|
||||
if (ret) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue