mirror of
https://github.com/intel/compute-runtime.git
synced 2025-12-22 10:17:01 +08:00
refactor: Unify getters to check platform support for KMD migration
Related-To: NEO-6465 Signed-off-by: Milczarek, Slawomir <slawomir.milczarek@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
d236bcbba9
commit
ac9a96c07f
@@ -336,12 +336,9 @@ bool DrmAllocation::shouldAllocationPageFault(const Drm *drm) {
|
||||
return DebugManager.flags.EnableImplicitMigrationOnFaultableHardware.get();
|
||||
}
|
||||
|
||||
auto &productHelper = drm->getRootDeviceEnvironment().getHelper<ProductHelper>();
|
||||
auto isKmdMigrationSupported = productHelper.isKmdMigrationSupported();
|
||||
|
||||
switch (this->allocationType) {
|
||||
case AllocationType::UNIFIED_SHARED_MEMORY:
|
||||
return (DebugManager.flags.UseKmdMigration.get() == -1) ? isKmdMigrationSupported : DebugManager.flags.UseKmdMigration.get();
|
||||
return drm->hasKmdMigrationSupport();
|
||||
case AllocationType::BUFFER:
|
||||
return DebugManager.flags.UseKmdMigrationForBuffers.get() > 0;
|
||||
default:
|
||||
|
||||
Reference in New Issue
Block a user