diff options
| author | Jan Beich <jbeich@FreeBSD.org> | 2022-06-01 18:10:32 +0000 |
|---|---|---|
| committer | Jan Beich <jbeich@FreeBSD.org> | 2022-06-10 18:03:46 +0000 |
| commit | 49e8b5dd76fe28e7e846e824e0defcdbede64866 (patch) | |
| tree | 25bd97213d22174cfcc74d8f2a650f4ba005cb24 /lang/intel-compute-runtime/files/patch-userptr | |
| parent | c1b8b295583db63cef26fbeced118f6fce54ec22 (diff) | |
Diffstat (limited to 'lang/intel-compute-runtime/files/patch-userptr')
| -rw-r--r-- | lang/intel-compute-runtime/files/patch-userptr | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lang/intel-compute-runtime/files/patch-userptr b/lang/intel-compute-runtime/files/patch-userptr index 189b17e940a8..5d04bb042b36 100644 --- a/lang/intel-compute-runtime/files/patch-userptr +++ b/lang/intel-compute-runtime/files/patch-userptr @@ -38,16 +38,16 @@ frame #5: 0x000000080104b4e5 libigdrcl.so`NEO::DrmMemoryManager::DrmMemoryManage 60 } 61 } ---- shared/source/os_interface/linux/drm_memory_manager.cpp.orig 2022-04-25 08:39:54 UTC +--- shared/source/os_interface/linux/drm_memory_manager.cpp.orig 2022-06-01 18:10:32 UTC +++ shared/source/os_interface/linux/drm_memory_manager.cpp -@@ -246,7 +246,17 @@ NEO::BufferObject *DrmMemoryManager::allocUserptr(uint +@@ -248,7 +248,17 @@ NEO::BufferObject *DrmMemoryManager::allocUserptr(uint auto &drm = this->getDrm(rootDeviceIndex); - if (drm.ioctl(DRM_IOCTL_I915_GEM_USERPTR, &userptr) != 0) { + if (drm.ioctl(DrmIoctl::GemUserptr, &userptr) != 0) { - return nullptr; + if (errno == ENODEV && userptr.flags == 0) { + userptr.flags = I915_USERPTR_UNSYNCHRONIZED; -+ if (drm.ioctl(DRM_IOCTL_I915_GEM_USERPTR, &userptr) != 0) { ++ if (drm.ioctl(DrmIoctl::GemUserptr, &userptr) != 0) { + if (geteuid() != 0) { + printDebugString(true, stderr, "%s", "ioctl(I915_GEM_USERPTR) failed. Try running as root but expect poor stability.\n"); + } |
