From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by gabe.freedesktop.org (Postfix) with ESMTPS id 30CD010E14A for ; Wed, 5 Jul 2023 11:34:45 +0000 (UTC) Message-ID: <8375813f-4f7d-5a5c-602f-8906420b21ba@intel.com> Date: Wed, 5 Jul 2023 13:34:28 +0200 Content-Language: en-US From: Karolina Stolarek To: =?UTF-8?Q?Zbigniew_Kempczy=c5=84ski?= References: <20230704090104.120219-1-zbigniew.kempczynski@intel.com> <20230704090104.120219-2-zbigniew.kempczynski@intel.com> In-Reply-To: Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 8bit MIME-Version: 1.0 Subject: Re: [igt-dev] [PATCH i-g-t 01/12] lib/xe_query: Use vramN when returning string region name List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: igt-dev@lists.freedesktop.org Errors-To: igt-dev-bounces@lists.freedesktop.org Sender: "igt-dev" List-ID: On 5.07.2023 12:58, Karolina Stolarek wrote: > Hi Zbigniew, > > On 4.07.2023 11:00, Zbigniew Kempczyński wrote: >> For tests which are mixing regions (like xe_ccs) name is confusing. >> As an example might be example "subtest-name-vram-1-vram-1". It's >> more readable when it will be renamed to "subtest-name-vram1-vram1". > > Sounds good, but I wonder how it maps to the convention used in other > tests. In gem_ccs, iirc, we had "smem" and "lmemN". Could we reuse it here? Ah, OK, now I see these names are derived from drm_xe_memory_class. Ignore my comment then: Reviewed-by: Karolina Stolarek > > All the best, > Karolina > >> >> Signed-off-by: Zbigniew Kempczyński >> --- >>   lib/xe/xe_query.c | 4 ++-- >>   1 file changed, 2 insertions(+), 2 deletions(-) >> >> diff --git a/lib/xe/xe_query.c b/lib/xe/xe_query.c >> index 48fb5afba7..830b7e401d 100644 >> --- a/lib/xe/xe_query.c >> +++ b/lib/xe/xe_query.c >> @@ -445,7 +445,7 @@ struct drm_xe_query_mem_region *xe_mem_region(int >> fd, uint64_t region) >>    * xe_region_name: >>    * @region: region mask >>    * >> - * Returns region string like "system" or "vram-n" where n=0...62. >> + * Returns region string like "system" or "vramN" where N=0...62. >>    */ >>   const char *xe_region_name(uint64_t region) >>   { >> @@ -457,7 +457,7 @@ const char *xe_region_name(uint64_t region) >>           vrams = calloc(64, sizeof(char *)); >>           for (int i = 0; i < 64; i++) { >>               if (i != 0) >> -                asprintf(&vrams[i], "vram-%d", i - 1); >> +                asprintf(&vrams[i], "vram%d", i - 1); >>               else >>                   asprintf(&vrams[i], "system"); >>               igt_assert(vrams[i]);