Re: Issues with Chromium/Vulkan after upgrading vulkan to 1.2.190

From: Jan Beich <jbeich_at_FreeBSD.org>
Date: Wed, 08 Sep 2021 12:11:45 UTC
Pete Wright via freebsd-x11 <freebsd-x11@freebsd.org> writes:

>>> $ vulkaninfo
>>> ERROR at
>>> /wrkdirs/usr/ports/graphics/vulkan-tools/work/Vulkan-Tools-1.2.190/vulkaninfo/vulkaninfo.h:248:vkGetPhysicalDeviceSurfacePresentModesKHR
>>> failed with ERROR_UNKNOWN
>> Did you try to reboot? Sometimes GPU is wedged without triggering
>> GPU reset.
>> Does vulkaninfo and vkcube-display work fine on KMS console (e.g.,
>> ttyv0)?
>
> after i verified disabling vulkan in chrome i quit X and verified
> vulkaninfo works fine via a KMS console. i've attached the output of
> that to this email.

What did you use before console? If a Wayland compositor then NVIDIA GPU
maybe selected by default because discrete GPUs are favored over integrated.
As NVIDIA blob lacks KMS/GBM it cannot share buffers with Wayland compositor.
However, NVIDIA GPU can still be used for headless (CUDA, NVENC, OpenGL offscreen,
Vulkan Compute) or rendering to Xorg then forwarding to Wayland via VNC.

As a workaround try selecting the desired GPU either from within Vulkan
application or via vulkan-loader environ(7) variable e.g.,

$ vkcube-wayland --gpu_number 0
$ VK_ICD_FILENAMES=/usr/local/share/vulkan/icd.d/intel_icd.x86_64.json vkcube-wayland