From 910816010f24525fc2b9952c060f9eec50778657 Mon Sep 17 00:00:00 2001 From: "Vysochyn, Illia" Date: Wed, 8 Jan 2025 18:43:46 +0000 Subject: [PATCH] fix: Unify command parse for MEM_SET Related-To: NEO-13147 Signed-off-by: Vysochyn, Illia --- .../xe_hpc_core/hw_cmds_generated_xe_hpc_core.inl | 8 ++++---- shared/test/common/cmd_parse/cmd_parse_mem_set.inl | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/shared/source/generated/xe_hpc_core/hw_cmds_generated_xe_hpc_core.inl b/shared/source/generated/xe_hpc_core/hw_cmds_generated_xe_hpc_core.inl index ff9cbcf322..8a9d6105b3 100644 --- a/shared/source/generated/xe_hpc_core/hw_cmds_generated_xe_hpc_core.inl +++ b/shared/source/generated/xe_hpc_core/hw_cmds_generated_xe_hpc_core.inl @@ -7264,9 +7264,9 @@ typedef struct tagMEM_SET { typedef enum tagCLIENT { CLIENT_2D_PROCESSOR = 0x2, } CLIENT; - typedef enum tagINSTRUCTIONTARGET_OPCODE { - INSTRUCTIONTARGET_OPCODE_OPCODE = 0x5B, - } INSTRUCTIONTARGET_OPCODE; + typedef enum tagINSTRUCTION_TARGETOPCODE { + INSTRUCTION_TARGETOPCODE_MEM_SET = 0x5b, + } INSTRUCTION_TARGETOPCODE; inline void init() { memset(&TheStructure, 0, sizeof(TheStructure)); TheStructure.Common.DwordLength = DWORD_LENGTH_EXCLUDES_DWORD_0_1; @@ -7274,7 +7274,7 @@ typedef struct tagMEM_SET { TheStructure.Common.DestinationCompressible = DESTINATION_COMPRESSIBLE_NOT_COMPRESSIBLE; TheStructure.Common.FillType = FILL_TYPE_LINEAR_FILL; TheStructure.Common.Client = CLIENT_2D_PROCESSOR; - TheStructure.Common.InstructionTarget_Opcode = INSTRUCTIONTARGET_OPCODE::INSTRUCTIONTARGET_OPCODE_OPCODE; + TheStructure.Common.InstructionTarget_Opcode = INSTRUCTION_TARGETOPCODE::INSTRUCTION_TARGETOPCODE_MEM_SET; } static tagMEM_SET sInit() { MEM_SET state; diff --git a/shared/test/common/cmd_parse/cmd_parse_mem_set.inl b/shared/test/common/cmd_parse/cmd_parse_mem_set.inl index 9e626ee511..881866b851 100644 --- a/shared/test/common/cmd_parse/cmd_parse_mem_set.inl +++ b/shared/test/common/cmd_parse/cmd_parse_mem_set.inl @@ -1,5 +1,5 @@ /* - * Copyright (C) 2024 Intel Corporation + * Copyright (C) 2024-2025 Intel Corporation * * SPDX-License-Identifier: MIT * @@ -14,9 +14,9 @@ template <> MEM_SET *genCmdCast(void *buffer) { auto pCmd = reinterpret_cast(buffer); - return (0x5 == pCmd->TheStructure.Common.DwordLength && - 0x5B == pCmd->TheStructure.Common.InstructionTarget_Opcode && - 0x2 == pCmd->TheStructure.Common.Client) + return (MEM_SET::DWORD_LENGTH::DWORD_LENGTH_EXCLUDES_DWORD_0_1 == pCmd->TheStructure.Common.DwordLength && + MEM_SET::INSTRUCTION_TARGETOPCODE::INSTRUCTION_TARGETOPCODE_MEM_SET == pCmd->TheStructure.Common.InstructionTarget_Opcode && + MEM_SET::CLIENT::CLIENT_2D_PROCESSOR == pCmd->TheStructure.Common.Client) ? pCmd : nullptr; }