mirror of
https://github.com/intel/compute-runtime.git
synced 2025-12-21 09:14:47 +08:00
Create HardwareContext only when osContext is available
Change-Id: I8bcf2cb20f0e1e6b9da98b477f5be206407a7a57 Signed-off-by: Dunajski, Bartosz <bartosz.dunajski@intel.com>
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2017-2018 Intel Corporation
|
||||
* Copyright (C) 2017-2019 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -176,7 +176,7 @@ bool Device::createEngines(const HardwareInfo *pHwInfo, Device &outDevice) {
|
||||
|
||||
auto osContext = executionEnvironment->memoryManager->createAndRegisterOsContext(gpgpuEngineInstances[deviceCsrIndex], outDevice.preemptionMode);
|
||||
auto commandStreamReceiver = executionEnvironment->commandStreamReceivers[outDevice.getDeviceIndex()][deviceCsrIndex].get();
|
||||
commandStreamReceiver->setOsContext(*osContext);
|
||||
commandStreamReceiver->setupContext(*osContext);
|
||||
if (!commandStreamReceiver->initializeTagAllocation()) {
|
||||
return false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user