From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga07.intel.com (mga07.intel.com [134.134.136.100]) by gabe.freedesktop.org (Postfix) with ESMTPS id 7D97A10E49C for ; Wed, 17 May 2023 21:25:47 +0000 (UTC) From: Umesh Nerlige Ramappa To: igt-dev@lists.freedesktop.org Date: Wed, 17 May 2023 14:25:38 -0700 Message-Id: <20230517212542.3681862-12-umesh.nerlige.ramappa@intel.com> In-Reply-To: <20230517212542.3681862-1-umesh.nerlige.ramappa@intel.com> References: <20230517212542.3681862-1-umesh.nerlige.ramappa@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [igt-dev] [PATCH i-g-t v2 11/15] intel_gpu_top: Bump up size of groups to accomodate multi-gt List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: igt-dev-bounces@lists.freedesktop.org Sender: "igt-dev" List-ID: Create more space in groups to add gt specific freq and rc6 groups. Signed-off-by: Umesh Nerlige Ramappa Reviewed-by: Tvrtko Ursulin --- tools/intel_gpu_top.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/tools/intel_gpu_top.c b/tools/intel_gpu_top.c index c8b6b92dd..9bb933cab 100644 --- a/tools/intel_gpu_top.c +++ b/tools/intel_gpu_top.c @@ -1511,7 +1511,13 @@ print_header(const struct igt_device_card *card, .display_name = "Power W", .items = power_items, }; - struct cnt_group *groups[] = { + /* + * Array size calculation: + * One group each for period, irq, power, NULL = 4 + * One group per gt for freq = MAX_GTS + * One group per gt for rc6 = MAX_GTS + */ + struct cnt_group *groups[4 + MAX_GTS + MAX_GTS] = { &period_group, &freq_group, &irq_group, -- 2.36.1