From 62ca7bdc57fb369d953dfa1827eac40c13f07c1e Mon Sep 17 00:00:00 2001 From: "Warchulski, Jaroslaw" Date: Fri, 12 Jan 2024 13:35:08 +0000 Subject: [PATCH] fix: don't unregister csr clients in EventImp::reset() Related-To: GSD-7129 Signed-off-by: Warchulski, Jaroslaw Source: d1061cd923e6bff6f22bae6e47dd4e74c7a1430a --- level_zero/core/source/event/event_impl.inl | 2 +- .../core/test/unit_tests/sources/cmdlist/test_cmdlist_1.cpp | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/level_zero/core/source/event/event_impl.inl b/level_zero/core/source/event/event_impl.inl index ac87de0150318..6c69e28cec795 100644 --- a/level_zero/core/source/event/event_impl.inl +++ b/level_zero/core/source/event/event_impl.inl @@ -566,7 +566,7 @@ ze_result_t EventImp::reset() { } unsetInOrderExecInfo(); - unsetCmdQueue(); + latestUsedCmdQueue = nullptr; this->resetCompletionStatus(); this->resetDeviceCompletionData(false); this->l3FlushAppliedOnKernel.reset(); diff --git a/level_zero/core/test/unit_tests/sources/cmdlist/test_cmdlist_1.cpp b/level_zero/core/test/unit_tests/sources/cmdlist/test_cmdlist_1.cpp index e5d8e72e047e3..fb455ac498115 100644 --- a/level_zero/core/test/unit_tests/sources/cmdlist/test_cmdlist_1.cpp +++ b/level_zero/core/test/unit_tests/sources/cmdlist/test_cmdlist_1.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2020-2023 Intel Corporation + * Copyright (C) 2020-2024 Intel Corporation * * SPDX-License-Identifier: MIT * @@ -1359,7 +1359,7 @@ HWTEST_F(CommandListCreate, givenSignalEventWhenCallingSynchronizeThenUnregister zeEventHostReset(event3); zeEventHostSynchronize(event3, 1); - EXPECT_EQ(ultCsr->getNumClients(), 0u); + EXPECT_EQ(ultCsr->getNumClients(), 1u); } zeEventDestroy(event1);