@@ -587,7 +587,7 @@ uint32_t DeviceImp::getMaxNumHwThreads() const { return maxNumHwThreads; }
587587
588588const NEO::HardwareInfo &DeviceImp::getHwInfo () const { return neoDevice->getHardwareInfo (); }
589589
590- Device *Device::create (DriverHandle *driverHandle, NEO::Device *neoDevice, uint32_t currentDeviceMask, bool isSubDevice) {
590+ Device *Device::create (DriverHandle *driverHandle, NEO::Device *neoDevice, uint32_t currentDeviceMask, bool isSubDevice, ze_result_t *returnValue ) {
591591 auto device = new DeviceImp;
592592 UNRECOVERABLE_IF (device == nullptr );
593593
@@ -629,7 +629,7 @@ Device *Device::create(DriverHandle *driverHandle, NEO::Device *neoDevice, uint3
629629 ze_device_handle_t subDevice = Device::create (driverHandle,
630630 device->neoDevice ->getDeviceById (i),
631631 0 ,
632- true );
632+ true , returnValue );
633633 if (subDevice == nullptr ) {
634634 return nullptr ;
635635 }
@@ -646,6 +646,8 @@ Device *Device::create(DriverHandle *driverHandle, NEO::Device *neoDevice, uint3
646646 auto sipType = NEO::SipKernel::getSipKernelType (hwInfo.platform .eRenderCoreFamily , neoDevice->getDebugger ());
647647 NEO::initSipKernel (sipType, *neoDevice);
648648 }
649+ } else {
650+ *returnValue = ZE_RESULT_ERROR_DEPENDENCY_UNAVAILABLE;
649651 }
650652
651653 auto supportDualStorageSharedMemory = neoDevice->getMemoryManager ()->isLocalMemorySupported (device->neoDevice ->getRootDeviceIndex ());
@@ -660,10 +662,10 @@ Device *Device::create(DriverHandle *driverHandle, NEO::Device *neoDevice, uint3
660662 cmdQueueDesc.flags = 0 ;
661663 cmdQueueDesc.stype = ZE_STRUCTURE_TYPE_COMMAND_QUEUE_DESC;
662664 cmdQueueDesc.mode = ZE_COMMAND_QUEUE_MODE_SYNCHRONOUS;
663- ze_result_t returnValue = ZE_RESULT_SUCCESS;
665+ ze_result_t resultValue = ZE_RESULT_SUCCESS;
664666 device->pageFaultCommandList =
665667 CommandList::createImmediate (
666- device->neoDevice ->getHardwareInfo ().platform .eProductFamily , device, &cmdQueueDesc, true , NEO::EngineGroupType::RenderCompute, returnValue );
668+ device->neoDevice ->getHardwareInfo ().platform .eProductFamily , device, &cmdQueueDesc, true , NEO::EngineGroupType::RenderCompute, resultValue );
667669 }
668670
669671 if (device->getSourceLevelDebugger ()) {
0 commit comments