DaVinci Resolve 16 crashes drm error

Hi,

I have and issue with one app ‘DaVinci Resolve 16’ that crashes on load.

When that happens, I am getting drm errors under dmesg:

[  132.816594] nvidia-uvm: Loaded the UVM driver, major device number 234.
[  134.405585] [drm:nv_drm_gem_fence_attach_ioctl [nvidia_drm]] *ERROR* [nvidia-drm] [GPU ID 0x00000300] Failed to lookup gem object for fence attach: 0x00000004

I saw some other people having similar error and crash’es so I was hoping that someone here might have some ideas

$ grep modeset /etc/modprobe.d/* /lib/modprobe.d/*

/etc/modprobe.d/nvidia-installer-disable-nouveau.conf:options nouveau modeset=0
/lib/modprobe.d/nvidia-installer-disable-nouveau.conf:options nouveau modeset=0
Fedora 29 (MATE-Compiz)
$  uname -r
5.2.11-100.fc29.x86_64
$  nvidia-smi 
Wed Sep 11 22:59:19 2019       
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 435.21       Driver Version: 435.21       CUDA Version: 10.1     |
|-------------------------------+----------------------+----------------------+
CUDA Device Query (Runtime API) version (CUDART static linking)

Detected 1 CUDA Capable device(s)

Device 0: "GeForce GTX TITAN X"
  CUDA Driver Version / Runtime Version          10.1 / 10.0
  CUDA Capability Major/Minor version number:    5.2
  Total amount of global memory:                 12212 MBytes (12805668864 bytes)
  (24) Multiprocessors, (128) CUDA Cores/MP:     3072 CUDA Cores
  GPU Max Clock rate:                            1076 MHz (1.08 GHz)
  Memory Clock rate:                             3505 Mhz
  Memory Bus Width:                              384-bit
  L2 Cache Size:                                 3145728 bytes
  Maximum Texture Dimension Size (x,y,z)         1D=(65536), 2D=(65536, 65536), 3D=(4096, 4096, 4096)
  Maximum Layered 1D Texture Size, (num) layers  1D=(16384), 2048 layers
  Maximum Layered 2D Texture Size, (num) layers  2D=(16384, 16384), 2048 layers
  Total amount of constant memory:               65536 bytes
  Total amount of shared memory per block:       49152 bytes
  Total number of registers available per block: 65536
  Warp size:                                     32
  Maximum number of threads per multiprocessor:  2048
  Maximum number of threads per block:           1024
  Max dimension size of a thread block (x,y,z): (1024, 1024, 64)
  Max dimension size of a grid size    (x,y,z): (2147483647, 65535, 65535)
  Maximum memory pitch:                          2147483647 bytes
  Texture alignment:                             512 bytes
  Concurrent copy and kernel execution:          Yes with 2 copy engine(s)
  Run time limit on kernels:                     Yes
  Integrated GPU sharing Host Memory:            No
  Support host page-locked memory mapping:       Yes
  Alignment requirement for Surfaces:            Yes
  Device has ECC support:                        Disabled
  Device supports Unified Addressing (UVA):      Yes
  Device supports Compute Preemption:            No
  Supports Cooperative Kernel Launch:            No
  Supports MultiDevice Co-op Kernel Launch:      No
  Device PCI Domain ID / Bus ID / location ID:   0 / 3 / 0
  Compute Mode:
     < Default (multiple host threads can use ::cudaSetDevice() with device simultaneously) >

deviceQuery, CUDA Driver = CUDART, CUDA Driver Version = 10.1, CUDA Runtime Version = 10.0, NumDevs = 1
Result = PASS
[New Thread 0x7ffef56d0700 (LWP 13068)]
[New Thread 0x7ffee2614700 (LWP 13069)]
Thread 481 "resolve" received signal SIGABRT, Aborted.
[Switching to Thread 0x7ffee2614700 (LWP 13069)]
0x00007fffc76a457f in raise () from /lib64/libc.so.6
(gdb) backtrace
#0  0x00007fffc76a457f in raise () at /lib64/libc.so.6
#1  0x00007fffc768e895 in abort () at /lib64/libc.so.6
#2  0x0000000007598fdd in __gnu_cxx::__verbose_terminate_handler() ()
#3  0x0000000007582286 in  ()
#4  0x00000000075822d1 in  ()
#5  0x00007ffff7d2e26e in  () at /opt/resolve/bin/../libs/libc++.so.1
#6  0x0000000001f13de7 in  ()
#7  0x00007fffc76a6d1c in __run_exit_handlers () at /lib64/libc.so.6
#8  0x00007fffc76a6e50 in on_exit () at /lib64/libc.so.6
#9  0x00007fffb76aa3e5 in  () at /lib64/libpocl.so.2.2.0
#10 0x00007fffcd4b2ab3 in  () at /usr/local/cuda/lib64/libOpenCL.so.1
#11 0x0000000005ef314b in  ()
#12 0x0000000005ef35b4 in  ()
#13 0x0000000005ef65dd in  ()
#14 0x0000000005e2cbdc in  ()
#15 0x0000000005e2cce4 in  ()
#16 0x000000000216e0fd in  ()
#17 0x000000000217252d in  ()
#18 0x00007fffc957658e in start_thread () at /lib64/libpthread.so.0
#19 0x00007fffc7769713 in clone () at /lib64/libc.so.6
(gdb)

Now that’s mighty little info. Desktop or notebook? Distro? GPU model?
The error in dmesg is related to PRIME sync, in case of Ubuntu, try this:
Please run
grep modeset /etc/modprobe.d/* /lib/modprobe.d/*
to find the file containing
options nvidia-drm modeset=1
and change it to
options nvidia-drm modeset=0
then run
sudo update-initramfs -u
and reboot.

Hey generix! Thanks for reply! looks like most of your questions are already answered in my initial post, I even had your suggested command set run and I had provided its output - it was set to 0

As for the missing info:
It is a Desktop, GeForce GTX TITAN X

Hope that clear things out!

Cheers!

Not really. Only by the kernel version I can deduct that youre using Fedora 29.
Please post the output of

sudo cat /sys/module/nvidia_drm/parameters/modeset

Yes, sorry, you’re correct!

as for the output - it does not have much within it, just “N”.

$ sudo cat /sys/module/nvidia_drm/parameters/modeset
N

It only outputs either ‘Y’ or ‘N’. Since it’s ‘N’=No=Off this error message is really odd. Did you try downgrading the driver to either v430 or v418 to check if this is a regression?

I did. I’ve downgraded to 430.40 then 430.26 and 418.87 (which was part of cuda 10.1.243 package).
For 418 I even downgraded to kernel-4.18.16-300.fc29.x86_64 to properly install cuda 10.1 with its driver.

Main problem persisted with every driver version.

After that, I came back to 435.21 and kernel-5.2.11-100.fc29.x86_64.

just in case:

$  lsmod 
Module                  Size  Used by
nvidia_uvm           1036288  4
rpcsec_gss_krb5        45056  0
nfsv4                 704512  0
dns_resolver           16384  1 nfsv4
nfs                   323584  1 nfsv4
lockd                 118784  1 nfs
grace                  16384  1 lockd
fscache               393216  2 nfsv4,nfs
nf_conntrack_netbios_ns    16384  1
nf_conntrack_broadcast    16384  1 nf_conntrack_netbios_ns
xt_CT                  16384  1
fuse                  139264  3
ip6t_rpfilter          16384  1
ip6t_REJECT            16384  2
nf_reject_ipv6         20480  1 ip6t_REJECT
ipt_REJECT             16384  2
nf_reject_ipv4         16384  1 ipt_REJECT
xt_conntrack           16384  50
ebtable_nat            16384  1
ip6table_nat           16384  1
ip6table_mangle        16384  1
ip6table_raw           16384  1
ip6table_security      16384  1
iptable_nat            16384  1
nf_nat                 49152  2 ip6table_nat,iptable_nat
iptable_mangle         16384  1
iptable_raw            16384  1
iptable_security       16384  1
nf_conntrack          155648  5 xt_conntrack,nf_nat,nf_conntrack_netbios_ns,nf_conntrack_broadcast,xt_CT
nf_defrag_ipv6         24576  1 nf_conntrack
nf_defrag_ipv4         16384  1 nf_conntrack
libcrc32c              16384  2 nf_conntrack,nf_nat
ip_set                 57344  0
nfnetlink              16384  1 ip_set
ebtable_filter         16384  1
ebtables               40960  2 ebtable_nat,ebtable_filter
ip6table_filter        16384  1
ip6_tables             36864  7 ip6table_filter,ip6table_raw,ip6table_nat,ip6table_mangle,ip6table_security
iptable_filter         16384  1
ip_tables              32768  5 iptable_filter,iptable_security,iptable_raw,iptable_nat,iptable_mangle
b43                   454656  0
cordic                 16384  1 b43
mac80211              974848  1 b43
intel_rapl             28672  0
cfg80211              831488  2 b43,mac80211
sb_edac                24576  0
ssb                    94208  1 b43
x86_pkg_temp_thermal    20480  0
intel_powerclamp       20480  0
coretemp               20480  0
snd_hda_codec_hdmi     69632  1
mmc_core              180224  2 b43,ssb
kvm_intel             274432  0
rfkill                 28672  3 cfg80211
kvm                   749568  1 kvm_intel
snd_hda_codec_realtek   126976  1
iTCO_wdt               16384  0
snd_hda_codec_generic    94208  1 snd_hda_codec_realtek
iTCO_vendor_support    16384  1 iTCO_wdt
ledtrig_audio          16384  2 snd_hda_codec_generic,snd_hda_codec_realtek
snd_hda_intel          49152  6
irqbypass              16384  1 kvm
snd_usb_audio         270336  6
snd_hda_codec         159744  4 snd_hda_codec_generic,snd_hda_codec_hdmi,snd_hda_intel,snd_hda_codec_realtek
crct10dif_pclmul       16384  1
crc32_pclmul           16384  0
uvcvideo              114688  0
snd_hda_core          102400  5 snd_hda_codec_generic,snd_hda_codec_hdmi,snd_hda_intel,snd_hda_codec,snd_hda_codec_realtek
snd_usbmidi_lib        40960  1 snd_usb_audio
ghash_clmulni_intel    16384  0
snd_rawmidi            45056  1 snd_usbmidi_lib
intel_cstate           16384  0
videobuf2_vmalloc      20480  1 uvcvideo
snd_hwdep              16384  2 snd_usb_audio,snd_hda_codec
videobuf2_memops       20480  1 videobuf2_vmalloc
joydev                 28672  0
videobuf2_v4l2         28672  1 uvcvideo
intel_uncore          139264  0
snd_seq                86016  0
videobuf2_common       57344  2 videobuf2_v4l2,uvcvideo
cp210x                 40960  0
snd_seq_device         16384  2 snd_seq,snd_rawmidi
videodev              237568  3 videobuf2_v4l2,uvcvideo,videobuf2_common
wacom                 122880  0
snd_pcm               114688  6 snd_hda_codec_hdmi,snd_hda_intel,snd_usb_audio,snd_hda_codec,snd_hda_core
media                  61440  5 videodev,snd_usb_audio,videobuf2_v4l2,uvcvideo,videobuf2_common
intel_rapl_perf        16384  0
ipmi_si                69632  0
bcma                   65536  1 b43
ipmi_devintf           20480  0
snd_timer              40960  2 snd_seq,snd_pcm
i2c_i801               32768  0
lpc_ich                28672  0
snd                    94208  36 snd_hda_codec_generic,snd_seq,snd_seq_device,snd_hda_codec_hdmi,snd_hwdep,snd_hda_intel,snd_usb_audio,snd_usbmidi_lib,snd_hda_codec,snd_hda_codec_realtek,snd_timer,snd_pcm,snd_rawmidi
mei_me                 45056  0
pcc_cpufreq            20480  0
mei                   126976  1 mei_me
soundcore              16384  1 snd
auth_rpcgss           102400  1 rpcsec_gss_krb5
sunrpc                454656  9 nfsv4,auth_rpcgss,lockd,rpcsec_gss_krb5,nfs
binfmt_misc            24576  1
nvidia_drm             53248  5
nvidia_modeset       1126400  12 nvidia_drm
nvidia              19554304  900 nvidia_uvm,nvidia_modeset
mxm_wmi                16384  0
ipmi_msghandler        69632  3 ipmi_devintf,ipmi_si,nvidia
drm_kms_helper        225280  1 nvidia_drm
firewire_ohci          45056  0
isci                  159744  0
firewire_core          81920  1 firewire_ohci
crc32c_intel           24576  9
drm                   487424  8 drm_kms_helper,nvidia_drm
ixgbe                 397312  0
e1000e                286720  0
libsas                 98304  1 isci
crc_itu_t              16384  1 firewire_core
scsi_transport_sas     45056  2 isci,libsas
mdio                   16384  1 ixgbe
dca                    16384  1 ixgbe
wmi                    32768  1 mxm_wmi

Please check if you can work around this by setting the
nomodeset
kernel parameter. Or is this already set?

Tested just now:
I’ve added nomodeset /etc/sysconfig/grub

$ cat /etc/sysconfig/grub
GRUB_TIMEOUT=5
GRUB_DISTRIBUTOR="$(sed 's, release .*$,,g' /etc/system-release)"
GRUB_DEFAULT=saved
GRUB_DISABLE_SUBMENU=true
GRUB_TERMINAL_OUTPUT="console"
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash nomodeset"
GRUB_CMDLINE_LINUX="resume=/dev/mapper/fedora-swap rd.lvm.lv=fedora/root rd.lvm.lv=fedora/swap rhgb quiet rd.driver.blacklist=nouveau nomodeset"
GRUB_DISABLE_RECOVERY="true"

and I did run
$ grub2-mkconfig -o /boot/efi/EFI/fedora/grub.cfg

after the restart, I’ve check dmesg, no errors.
I’ve opened ‘resolve’ (application in question) which have crashed again and created dmesg error :

[   69.483894] nvidia-uvm: Loaded the UVM driver, major device number 234.
[   69.966515] [drm:nv_drm_gem_fence_attach_ioctl [nvidia_drm]] *ERROR* [nvidia-drm] [GPU ID 0x00000300] Failed to lookup gem object for fence attach: 0x00000004

Maybe the dmesg error is just a red herring. Please remove the nomodeset parameter again.
Looking at the backtrace, it loads opencl, please post the output of
clinfo

Thank you generix for all the suggestions so far!

I’ve removed nomodeset and rebuild grub - no change, same error. An interesting fact is that app Davinci Resolve 15 works fine (it’s an older version) with CUDA and OCL, but the current one - v16 is crashing. Sad is that their Developers are not supporting this distro, therefore won’t help. I was hoping that we would find some clue here :)

Installed clinfo and here is its output:
$clinfo

X server found. dri2 connection failed! 
DRM_IOCTL_I915_GEM_APERTURE failed: Invalid argument
Assuming 131072kB available aperture size.
May lead to reduced performance or incorrect rendering.
get chip id failed: -1 [22]
param: 4, val: 0
Number of platforms                               4
  Platform Name                                   Portable Computing Language
  Platform Vendor                                 The pocl project
  Platform Version                                OpenCL 1.2 pocl 1.2 RelWithDebInfo, LLVM 7.0.1, SLEEF, DISTRO, POCL_DEBUG
  Platform Profile                                FULL_PROFILE
  Platform Extensions                             cl_khr_icd
  Platform Extensions function suffix             POCL

  Platform Name                                   NVIDIA CUDA
  Platform Vendor                                 NVIDIA Corporation
  Platform Version                                OpenCL 1.2 CUDA 10.1.0
  Platform Profile                                FULL_PROFILE
  Platform Extensions                             cl_khr_global_int32_base_atomics cl_khr_global_int32_extended_atomics cl_khr_local_int32_base_atomics cl_khr_local_int32_extended_atomics cl_khr_fp64 cl_khr_byte_addressable_store cl_khr_icd cl_khr_gl_sharing cl_nv_compiler_options cl_nv_device_attribute_query cl_nv_pragma_unroll cl_nv_copy_opts cl_khr_gl_event cl_nv_create_buffer
  Platform Extensions function suffix             NV

  Platform Name                                   Clover
  Platform Vendor                                 Mesa
  Platform Version                                OpenCL 1.1 Mesa 18.3.6
  Platform Profile                                FULL_PROFILE
  Platform Extensions                             cl_khr_icd
  Platform Extensions function suffix             MESA

  Platform Name                                   Intel Gen OCL Driver
  Platform Vendor                                 Intel
  Platform Version                                OpenCL 2.0 beignet 1.3
  Platform Profile                                FULL_PROFILE
  Platform Extensions                             cl_khr_global_int32_base_atomics cl_khr_global_int32_extended_atomics cl_khr_local_int32_base_atomics cl_khr_local_int32_extended_atomics cl_khr_byte_addressable_store cl_khr_3d_image_writes cl_khr_image2d_from_buffer cl_khr_depth_images cl_khr_spir cl_khr_icd cl_intel_accelerator cl_intel_subgroups cl_intel_subgroups_short cl_khr_gl_sharing
  Platform Extensions function suffix             Intel
X server found. dri2 connection failed! 
DRM_IOCTL_I915_GEM_APERTURE failed: Invalid argument
Assuming 131072kB available aperture size.
May lead to reduced performance or incorrect rendering.
get chip id failed: -1 [22]
param: 4, val: 0
cl_get_gt_device(): error, unknown device: 0

  Platform Name                                   Portable Computing Language
Number of devices                                 1
  Device Name                                     pthread-Intel(R) Xeon(R) CPU E5-2630 v2 @ 2.60GHz
  Device Vendor                                   GenuineIntel
  Device Vendor ID                                0x6c636f70
  Device Version                                  OpenCL 1.2 pocl HSTR: pthread-x86_64-unknown-linux-gnu-ivybridge
  Driver Version                                  1.2
  Device OpenCL C Version                         OpenCL C 1.2 pocl
  Device Type                                     CPU
  Device Available                                Yes
  Device Profile                                  FULL_PROFILE
  Max compute units                               24
  Max clock frequency                             3100MHz
  Device Partition                                (core)
    Max number of sub-devices                     24
    Supported partition types                     equally, by counts
  Max work item dimensions                        3
  Max work item sizes                             4096x4096x4096
  Max work group size                             4096
  Compiler Available                              Yes
  Linker Available                                Yes
  Preferred work group size multiple              8
  Preferred / native vector sizes                 
    char                                                16 / 16      
    short                                               16 / 16      
    int                                                  8 / 8       
    long                                                 4 / 4       
    half                                                 0 / 0        (n/a)
    float                                                8 / 8       
    double                                               4 / 4        (cl_khr_fp64)
  Half-precision Floating-point support           (n/a)
  Single-precision Floating-point support         (core)
    Denormals                                     Yes
    Infinity and NANs                             Yes
    Round to nearest                              Yes
    Round to zero                                 Yes
    Round to infinity                             Yes
    IEEE754-2008 fused multiply-add               No
    Support is emulated in software               No
    Correctly-rounded divide and sqrt operations  Yes
  Double-precision Floating-point support         (cl_khr_fp64)
    Denormals                                     Yes
    Infinity and NANs                             Yes
    Round to nearest                              Yes
    Round to zero                                 Yes
    Round to infinity                             Yes
    IEEE754-2008 fused multiply-add               Yes
    Support is emulated in software               No
  Address bits                                    64, Little-Endian
  Global memory size                              132990914560 (123.9GiB)
  Error Correction support                        No
  Max memory allocation                           34359738368 (32GiB)
  Unified memory for Host and Device              Yes
  Minimum alignment for any data type             128 bytes
  Alignment of base address                       1024 bits (128 bytes)
  Global Memory cache type                        Read/Write
  Global Memory cache size                        15728640 (15MiB)
  Global Memory cache line size                   64 bytes
  Image support                                   Yes
    Max number of samplers per kernel             16
    Max size for 1D images from buffer            2147483648 pixels
    Max 1D or 2D image array size                 2048 images
    Max 2D image size                             32768x32768 pixels
    Max 3D image size                             2048x2048x2048 pixels
    Max number of read image args                 128
    Max number of write image args                128
  Local memory type                               Global
  Local memory size                               8388608 (8MiB)
  Max constant buffer size                        8388608 (8MiB)
  Max number of constant args                     8
  Max size of kernel argument                     1024
  Queue properties                                
    Out-of-order execution                        No
    Profiling                                     Yes
  Prefer user sync for interop                    Yes
  Profiling timer resolution                      1ns
  Execution capabilities                          
    Run OpenCL kernels                            Yes
    Run native kernels                            Yes
  printf() buffer size                            16777216 (16MiB)
  Built-in kernels                                
  Device Extensions                               cl_khr_byte_addressable_store cl_khr_global_int32_base_atomics cl_khr_global_int32_extended_atomics cl_khr_local_int32_base_atomics cl_khr_local_int32_extended_atomics cl_khr_3d_image_writes cl_khr_fp64 cl_khr_int64_base_atomics cl_khr_int64_extended_atomics cl_khr_fp64

  Platform Name                                   NVIDIA CUDA
Number of devices                                 1
  Device Name                                     GeForce GTX TITAN X
  Device Vendor                                   NVIDIA Corporation
  Device Vendor ID                                0x10de
  Device Version                                  OpenCL 1.2 CUDA
  Driver Version                                  435.21
  Device OpenCL C Version                         OpenCL C 1.2 
  Device Type                                     GPU
  Device Available                                Yes
  Device Profile                                  FULL_PROFILE
  Device Topology (NV)                            PCI-E, 03:00.0
  Max compute units                               24
  Max clock frequency                             1076MHz
  Compute Capability (NV)                         5.2
  Device Partition                                (core)
    Max number of sub-devices                     1
    Supported partition types                     None
  Max work item dimensions                        3
  Max work item sizes                             1024x1024x64
  Max work group size                             1024
  Compiler Available                              Yes
  Linker Available                                Yes
  Preferred work group size multiple              32
  Warp size (NV)                                  32
  Preferred / native vector sizes                 
    char                                                 1 / 1       
    short                                                1 / 1       
    int                                                  1 / 1       
    long                                                 1 / 1       
    half                                                 0 / 0        (n/a)
    float                                                1 / 1       
    double                                               1 / 1        (cl_khr_fp64)
  Half-precision Floating-point support           (n/a)
  Single-precision Floating-point support         (core)
    Denormals                                     Yes
    Infinity and NANs                             Yes
    Round to nearest                              Yes
    Round to zero                                 Yes
    Round to infinity                             Yes
    IEEE754-2008 fused multiply-add               Yes
    Support is emulated in software               No
    Correctly-rounded divide and sqrt operations  Yes
  Double-precision Floating-point support         (cl_khr_fp64)
    Denormals                                     Yes
    Infinity and NANs                             Yes
    Round to nearest                              Yes
    Round to zero                                 Yes
    Round to infinity                             Yes
    IEEE754-2008 fused multiply-add               Yes
    Support is emulated in software               No
  Address bits                                    64, Little-Endian
  Global memory size                              12805668864 (11.93GiB)
  Error Correction support                        No
  Max memory allocation                           3201417216 (2.982GiB)
  Unified memory for Host and Device              No
  Integrated memory (NV)                          No
  Minimum alignment for any data type             128 bytes
  Alignment of base address                       4096 bits (512 bytes)
  Global Memory cache type                        Read/Write
  Global Memory cache size                        1179648 (1.125MiB)
  Global Memory cache line size                   128 bytes
  Image support                                   Yes
    Max number of samplers per kernel             32
    Max size for 1D images from buffer            134217728 pixels
    Max 1D or 2D image array size                 2048 images
    Max 2D image size                             16384x16384 pixels
    Max 3D image size                             4096x4096x4096 pixels
    Max number of read image args                 256
    Max number of write image args                16
  Local memory type                               Local
  Local memory size                               49152 (48KiB)
  Registers per block (NV)                        65536
  Max constant buffer size                        65536 (64KiB)
  Max number of constant args                     9
  Max size of kernel argument                     4352 (4.25KiB)
  Queue properties                                
    Out-of-order execution                        Yes
    Profiling                                     Yes
  Prefer user sync for interop                    No
  Profiling timer resolution                      1000ns
  Execution capabilities                          
    Run OpenCL kernels                            Yes
    Run native kernels                            No
    Kernel execution timeout (NV)                 Yes
  Concurrent copy and kernel execution (NV)       Yes
    Number of async copy engines                  2
  printf() buffer size                            1048576 (1024KiB)
  Built-in kernels                                
  Device Extensions                               cl_khr_global_int32_base_atomics cl_khr_global_int32_extended_atomics cl_khr_local_int32_base_atomics cl_khr_local_int32_extended_atomics cl_khr_fp64 cl_khr_byte_addressable_store cl_khr_icd cl_khr_gl_sharing cl_nv_compiler_options cl_nv_device_attribute_query cl_nv_pragma_unroll cl_nv_copy_opts cl_khr_gl_event cl_nv_create_buffer

  Platform Name                                   Clover
Number of devices                                 0

  Platform Name                                   Intel Gen OCL Driver
Number of devices                                 0

NULL platform behavior
  clGetPlatformInfo(NULL, CL_PLATFORM_NAME, ...)  No platform
  clGetDeviceIDs(NULL, CL_DEVICE_TYPE_ALL, ...)   No platform
  clCreateContext(NULL, ...) [default]            No platform
  clCreateContext(NULL, ...) [other]              Success [POCL]
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_DEFAULT)  Success (1)
    Platform Name                                 Portable Computing Language
    Device Name                                   pthread-Intel(R) Xeon(R) CPU E5-2630 v2 @ 2.60GHz
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_CPU)  Success (1)
    Platform Name                                 Portable Computing Language
    Device Name                                   pthread-Intel(R) Xeon(R) CPU E5-2630 v2 @ 2.60GHz
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_GPU)  No devices found in platform
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_ACCELERATOR)  No devices found in platform
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_CUSTOM)  No devices found in platform
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_ALL)  Success (1)
    Platform Name                                 Portable Computing Language
    Device Name                                   pthread-Intel(R) Xeon(R) CPU E5-2630 v2 @ 2.60GHz

$ dnf list installed | grep opencl | sort

opencl-filesystem.noarch                      1.0-8.fc29                            @fedora                
opencl-headers.noarch                         2.2-2.20180306gite986688.fc29         @fedora                
opencl-utils-devel.x86_64                     1-8.svn16.fc29                        @fedora                
opencl-utils.x86_64                           1-8.svn16.fc29                        @fedora                
python3-pyopencl.x86_64                       2018.1.1-3.fc29                       @fedora                
wine-opencl.i686                              4.15-1.fc29                           @updates               
wine-opencl.x86_64                            4.15-1.fc29                           @updates

Ok, there seems to be the reason:

Platform Version   OpenCL 1.1 Mesa 18.3.6

Looks like you’ll have to clean up your icd files so it’s not trying to use mesa. That’s also where those drm errors come from.

Thanks!

I have no clue reg icd files so I need to read around.
I’ve tried simply removing mesa.icd but that did not change anything

ls -l /etc/OpenCL/vendors/

total 16
-rw-r--r--. 1 root root 29 Jul 21  2018 intel-beignet.icd
-rw-r--r--. 1 root root 19 Apr 16 12:10 mesa.icd
-r--r--r--. 1 root root 22 Sep 11 08:47 nvidia.icd
-rw-r--r--. 1 root root 16 Feb  8  2019 pocl.icd

dnf list installed | grep icd | sort

ocl-icd.i686                                  2.2.12-2.fc29                         @fedora                
ocl-icd.x86_64                                2.2.12-2.fc29                         @fedora

Google shows that people had some icd issues in the past https://forum.blackmagicdesign.com/viewtopic.php?f=21&t=56878&start=900

if you remove any files and only leave nvidia.icd in it, does clinfo correctly display only nvidia without any drm errors?

removing just mesa did nothing, removing ALL but nvidia.icd WORKED! - DaVinci started, no dmsg issues!

Once again, thanks for your time and help! And just to understand - Why this is a problem? Should Nvidia installer clear those files ?

Should I put back any of those files ? (do I need them?)

$  ls -l /etc/OpenCL/vendors/
total 4
-r--r--r--. 1 root root 22 Sep 11 08:47 nvidia.icd
$ clinfo 
Number of platforms                               1
  Platform Name                                   NVIDIA CUDA
  Platform Vendor                                 NVIDIA Corporation
  Platform Version                                OpenCL 1.2 CUDA 10.1.0
  Platform Profile                                FULL_PROFILE
  Platform Extensions                             cl_khr_global_int32_base_atomics cl_khr_global_int32_extended_atomics cl_khr_local_int32_base_atomics cl_khr_local_int32_extended_atomics cl_khr_fp64 cl_khr_byte_addressable_store cl_khr_icd cl_khr_gl_sharing cl_nv_compiler_options cl_nv_device_attribute_query cl_nv_pragma_unroll cl_nv_copy_opts cl_khr_gl_event cl_nv_create_buffer
  Platform Extensions function suffix             NV

  Platform Name                                   NVIDIA CUDA
Number of devices                                 1
  Device Name                                     GeForce GTX TITAN X
  Device Vendor                                   NVIDIA Corporation
  Device Vendor ID                                0x10de
  Device Version                                  OpenCL 1.2 CUDA
  Driver Version                                  435.21
  Device OpenCL C Version                         OpenCL C 1.2 
  Device Type                                     GPU
  Device Available                                Yes
  Device Profile                                  FULL_PROFILE
  Device Topology (NV)                            PCI-E, 03:00.0
  Max compute units                               24
  Max clock frequency                             1076MHz
  Compute Capability (NV)                         5.2
  Device Partition                                (core)
    Max number of sub-devices                     1
    Supported partition types                     None
  Max work item dimensions                        3
  Max work item sizes                             1024x1024x64
  Max work group size                             1024
  Compiler Available                              Yes
  Linker Available                                Yes
  Preferred work group size multiple              32
  Warp size (NV)                                  32
  Preferred / native vector sizes                 
    char                                                 1 / 1       
    short                                                1 / 1       
    int                                                  1 / 1       
    long                                                 1 / 1       
    half                                                 0 / 0        (n/a)
    float                                                1 / 1       
    double                                               1 / 1        (cl_khr_fp64)
  Half-precision Floating-point support           (n/a)
  Single-precision Floating-point support         (core)
    Denormals                                     Yes
    Infinity and NANs                             Yes
    Round to nearest                              Yes
    Round to zero                                 Yes
    Round to infinity                             Yes
    IEEE754-2008 fused multiply-add               Yes
    Support is emulated in software               No
    Correctly-rounded divide and sqrt operations  Yes
  Double-precision Floating-point support         (cl_khr_fp64)
    Denormals                                     Yes
    Infinity and NANs                             Yes
    Round to nearest                              Yes
    Round to zero                                 Yes
    Round to infinity                             Yes
    IEEE754-2008 fused multiply-add               Yes
    Support is emulated in software               No
  Address bits                                    64, Little-Endian
  Global memory size                              12805668864 (11.93GiB)
  Error Correction support                        No
  Max memory allocation                           3201417216 (2.982GiB)
  Unified memory for Host and Device              No
  Integrated memory (NV)                          No
  Minimum alignment for any data type             128 bytes
  Alignment of base address                       4096 bits (512 bytes)
  Global Memory cache type                        Read/Write
  Global Memory cache size                        1179648 (1.125MiB)
  Global Memory cache line size                   128 bytes
  Image support                                   Yes
    Max number of samplers per kernel             32
    Max size for 1D images from buffer            134217728 pixels
    Max 1D or 2D image array size                 2048 images
    Max 2D image size                             16384x16384 pixels
    Max 3D image size                             4096x4096x4096 pixels
    Max number of read image args                 256
    Max number of write image args                16
  Local memory type                               Local
  Local memory size                               49152 (48KiB)
  Registers per block (NV)                        65536
  Max constant buffer size                        65536 (64KiB)
  Max number of constant args                     9
  Max size of kernel argument                     4352 (4.25KiB)
  Queue properties                                
    Out-of-order execution                        Yes
    Profiling                                     Yes
  Prefer user sync for interop                    No
  Profiling timer resolution                      1000ns
  Execution capabilities                          
    Run OpenCL kernels                            Yes
    Run native kernels                            No
    Kernel execution timeout (NV)                 Yes
  Concurrent copy and kernel execution (NV)       Yes
    Number of async copy engines                  2
  printf() buffer size                            1048576 (1024KiB)
  Built-in kernels                                
  Device Extensions                               cl_khr_global_int32_base_atomics cl_khr_global_int32_extended_atomics cl_khr_local_int32_base_atomics cl_khr_local_int32_extended_atomics cl_khr_fp64 cl_khr_byte_addressable_store cl_khr_icd cl_khr_gl_sharing cl_nv_compiler_options cl_nv_device_attribute_query cl_nv_pragma_unroll cl_nv_copy_opts cl_khr_gl_event cl_nv_create_buffer

NULL platform behavior
  clGetPlatformInfo(NULL, CL_PLATFORM_NAME, ...)  No platform
  clGetDeviceIDs(NULL, CL_DEVICE_TYPE_ALL, ...)   No platform
  clCreateContext(NULL, ...) [default]            No platform
  clCreateContext(NULL, ...) [other]              Success [NV]
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_DEFAULT)  No platform
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_CPU)  No devices found in platform
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_GPU)  No platform
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_ACCELERATOR)  No devices found in platform
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_CUSTOM)  No devices found in platform
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_ALL)  No platform

I think the distribution should take care of which .icd files get installed/used. You won’t need them unless you’re putting in an intel gpu and want to use it for OpenCL or use your CPU for OpenCL.
Only thing is that you might have to remove the files again after updates of the respective packages. Maybe remove those (pocl/beignet).

这个问题,也是我一直纠结的问题,希望可以在Fedora32里运行Davinci resolve studio16.2.nvidia 1080ti gpu.BMD的centos7.3版本,还是太老了。很多附加软件都是没有办法使用的。Ubuntu20.04LTS上运行Davinci resolve studio16.2,只是需要解决安装部分依赖文件就可以了。包括18.04LTS、19.10都可以哈。