Files
compute-runtime/shared/source/os_interface/windows/hw_device_id_win.cpp
kamdiedrich e072275ae6 Reorganization directory structure [3/n]
Change-Id: If3dfa3f6007f8810a6a1ae1a4f0c7da38544648d
2020-02-23 23:48:28 +01:00

24 lines
866 B
C++

/*
* Copyright (C) 2020 Intel Corporation
*
* SPDX-License-Identifier: MIT
*
*/
#include "helpers/debug_helpers.h"
#include "os_interface/windows/gdi_interface.h"
#include "os_interface/windows/hw_device_id.h"
namespace NEO {
HwDeviceId::~HwDeviceId() {
NTSTATUS status = STATUS_UNSUCCESSFUL;
D3DKMT_CLOSEADAPTER CloseAdapter = {0};
CloseAdapter.hAdapter = adapter;
status = gdi->closeAdapter(&CloseAdapter);
DEBUG_BREAK_IF(status != STATUS_SUCCESS);
}
HwDeviceId::HwDeviceId(D3DKMT_HANDLE adapterIn, LUID adapterLuidIn, std::unique_ptr<Gdi> gdiIn) : adapter(adapterIn),
adapterLuid(adapterLuidIn),
gdi(std::move(gdiIn)){};
} // namespace NEO