From 84ada12002501014c29bec4e2ecf5cc2bcc919a6 Mon Sep 17 00:00:00 2001 From: Lionel Landwerlin Date: Thu, 21 Jul 2022 07:46:50 +0000 Subject: [PATCH] intel/perf: allocate cleared counter infos This array of structure needs to be initialized to 0 as it contains a bitset we don't explicitly clear. Signed-off-by: Lionel Landwerlin Fixes: 3144bc1d3369 ("intel/perf: move query_mask and location out of gen_perf_query_counter") Reviewed-by: Ivan Briano Part-of: (cherry picked from commit e754bf6be49788e5f6604a15cd36a3324fd94a39) --- .pick_status.json | 2 +- src/intel/perf/intel_perf.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.pick_status.json b/.pick_status.json index 0c2032d79d9..f551e69a27e 100644 --- a/.pick_status.json +++ b/.pick_status.json @@ -2596,7 +2596,7 @@ "description": "intel/perf: allocate cleared counter infos", "nominated": true, "nomination_type": 1, - "resolution": 0, + "resolution": 1, "main_sha": null, "because_sha": "3144bc1d33692ed35c6431bca57d3b0d46330cde" }, diff --git a/src/intel/perf/intel_perf.c b/src/intel/perf/intel_perf.c index eca169efed8..5841456a0f3 100644 --- a/src/intel/perf/intel_perf.c +++ b/src/intel/perf/intel_perf.c @@ -649,7 +649,7 @@ build_unique_counter_list(struct intel_perf_config *perf) * below contains pointers to this array. */ struct intel_perf_query_counter_info *counter_infos = - ralloc_array_size(perf, sizeof(counter_infos[0]), max_counters); + rzalloc_array_size(perf, sizeof(counter_infos[0]), max_counters); perf->n_counters = 0;