You are not logged in.

#1 2024-09-21 20:22:41

Neroman
Member
Registered: 2024-09-13
Posts: 21

Kinda confused with VA-API on Dual GPU. NVidia/Intel issues Hyprland

Hi. Was trying to make XWayland application (Vesktop) running with Intel VA-API instead of NVidia. It was kinda working but was always getting an issue (couldn't watch screenshare stream, white screen and ozone issue), so I decided switch back to NVDECK. Idk what i did, but when I switched back from 'iHD' to 'nvidia' got this error: (was trying to search and fix it myself, but i don't understand why i915 is here)

NVD_LOG=1 vainfo

Trying display: wayland
       101.484854619 [15930-15930] ../nvidia-vaapi-driver-0.0.12/src/vabackend.c:2188       __vaDriverInit_1_0 Initialising NVIDIA VA-API Driver: 40
       101.484864389 [15930-15930] ../nvidia-vaapi-driver-0.0.12/src/vabackend.c:2197       __vaDriverInit_1_0 Now have 0 (0 max) instances
       101.484867467 [15930-15930] ../nvidia-vaapi-driver-0.0.12/src/vabackend.c:2223       __vaDriverInit_1_0 Selecting Direct backend
       101.502712319 [15930-15930] ../nvidia-vaapi-driver-0.0.12/src/backend-common.c:  31            isNvidiaDrmFd Invalid driver for DRM device: i915
       101.502721063 [15930-15930] ../nvidia-vaapi-driver-0.0.12/src/vabackend.c:2248       __vaDriverInit_1_0 Exporter failed
libva error: /usr/lib/dri/nvidia_drv_video.so init failed
vaInitialize failed with error code 1 (operation failed),exit

pacman -Qs libva (but no response from 'pacman -Fy libva-nvidia-driver)

local/lib32-libva 2.22.0-1
    Video Acceleration (VA) API for Linux (32-bit)
local/lib32-libva-vdpau-driver 0.7.4-8
    VDPAU backend for VA API (32-bit)
local/libva 2.22.0-1
    Video Acceleration (VA) API for Linux
local/libva-intel-driver 2.4.1-3
    VA-API implementation for Intel G45 and HD Graphics family
local/libva-nvidia-driver 0.0.12-1
    VA-API implementation that uses NVDEC as a backend
local/libva-utils 2.22.0-1
    Intel VA-API Media Applications and Scripts for libva

lscpi

00:02.0 VGA compatible controller: Intel Corporation Comet Lake-H GT1 [UHD Graphics 610] (rev 05)
01:00.0 VGA compatible controller: NVIDIA Corporation TU117M [GeForce GTX 1650 Ti Mobile] (rev a1)

cat .config/hypr/hyprland.conf | grep env

exec-once = dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP
env = XCURSOR_SIZE,20
env = HYPRCURSOR_SIZE,20
env = XDG_CURRENT_DESKTOP,Hyprland
env = XDG_SESSION_TYPE,wayland
env = XDG_SESSION_DESKTOP,Hyprland
env = XDG_CONFIG_HOME,$HOME/.config
env = GDK_BACKEND,wayland,x11,*			# GTK: Use wayland if available
env = SDL_VIDEODRIVER,wayland			# Run SDL2 applications on Wayland
env = CLUTTER_BACKEND,wayland			# force Clutter applications to Wayland/
env = QT_QPA_PLATFORM,wayland;xcb		# Qt: Use wayland if available
env = QT_QPA_PLATFORMTHEME,qt6ct		# pick up theme from qt6ct
env = QT_QPA_PLATFORMTHEME,qt5ct		# pick up theme from qt5ct, kvantum
env = QT_WAYLAND_DISABLE_WINDOWDECORATION,1	# disables window decorations
env = QT_AUTO_SCREEN_SCALE_FACTOR,1		# enables automatic scaling
env = LIBVA_DRIVER_NAME,nvidia
env = GBM_BACKEND,nvidia-drm
env = __GLX_VENDOR_LIBRARY_NAME,nvidia
env = NVD_BACKEND,direct
env = MOZ_ENABLE_WAYLAND,1
env = APPIMAGELAUNCHER_DISABLE,1
env = OZONE_PLATFORM,wayland
env = ELECTRON_OZONE_PLATFORM_HINT,wayland

pacman -Qs nvidia

local/cuda 12.6.1-1
    NVIDIA's GPU programming toolkit
local/egl-gbm 1.1.2-1
    The GBM EGL external platform library
local/egl-wayland 4:1.1.16-1
    EGLStream-based Wayland external platform
local/ffnvcodec-headers 12.2.72.0-1
    FFmpeg version of headers required to interface with Nvidias codec APIs
local/lib32-egl-wayland 1.1.16-1
    EGLStream-based Wayland external platform (32-bits)
local/lib32-libvdpau 1.5-3
    Nvidia VDPAU library
local/lib32-nvidia-utils 560.35.03-1
    NVIDIA drivers utilities (32-bit)
local/lib32-opencl-nvidia 560.35.03-1
    OpenCL implemention for NVIDIA (32-bit)
local/libva-nvidia-driver 0.0.12-1
    VA-API implementation that uses NVDEC as a backend
local/libvdpau 1.5-3
    Nvidia VDPAU library
local/libxnvctrl 560.35.03-1
    NVIDIA NV-CONTROL X extension
local/nvidia-dkms 560.35.03-3
    NVIDIA drivers - module sources
local/nvidia-settings 560.35.03-1
    Tool for configuring the NVIDIA graphics driver
local/nvidia-utils 560.35.03-3
    NVIDIA drivers utilities
local/nvtop 3.1.0-1
    GPUs process monitoring for AMD, Intel and NVIDIA
local/opencl-nvidia 560.35.03-3
    OpenCL implemention for NVIDIA

Thanks!

Last edited by Neroman (2024-09-21 20:30:03)

Offline

#2 2024-09-21 20:29:12

Neroman
Member
Registered: 2024-09-13
Posts: 21

Re: Kinda confused with VA-API on Dual GPU. NVidia/Intel issues Hyprland

VA-API with iHD:

Trying display: wayland
vainfo: VA-API version: 1.22 (libva 2.22.0)
vainfo: Driver version: Intel iHD driver for Intel(R) Gen Graphics - 24.3.3 ()
vainfo: Supported profile and entrypoints
      VAProfileNone                   :	VAEntrypointVideoProc
      VAProfileNone                   :	VAEntrypointStats
      VAProfileMPEG2Simple            :	VAEntrypointVLD
      VAProfileMPEG2Simple            :	VAEntrypointEncSlice
      VAProfileMPEG2Main              :	VAEntrypointVLD
      VAProfileMPEG2Main              :	VAEntrypointEncSlice
      VAProfileH264Main               :	VAEntrypointVLD
      VAProfileH264Main               :	VAEntrypointEncSlice
      VAProfileH264Main               :	VAEntrypointFEI
      VAProfileH264Main               :	VAEntrypointEncSliceLP
      VAProfileH264High               :	VAEntrypointVLD
      VAProfileH264High               :	VAEntrypointEncSlice
      VAProfileH264High               :	VAEntrypointFEI
      VAProfileH264High               :	VAEntrypointEncSliceLP
      VAProfileVC1Simple              :	VAEntrypointVLD
      VAProfileVC1Main                :	VAEntrypointVLD
      VAProfileVC1Advanced            :	VAEntrypointVLD
      VAProfileJPEGBaseline           :	VAEntrypointVLD
      VAProfileJPEGBaseline           :	VAEntrypointEncPicture
      VAProfileH264ConstrainedBaseline:	VAEntrypointVLD
      VAProfileH264ConstrainedBaseline:	VAEntrypointEncSlice
      VAProfileH264ConstrainedBaseline:	VAEntrypointFEI
      VAProfileH264ConstrainedBaseline:	VAEntrypointEncSliceLP
      VAProfileVP8Version0_3          :	VAEntrypointVLD
      VAProfileVP8Version0_3          :	VAEntrypointEncSlice
      VAProfileHEVCMain               :	VAEntrypointVLD
      VAProfileHEVCMain               :	VAEntrypointEncSlice
      VAProfileHEVCMain               :	VAEntrypointFEI
      VAProfileHEVCMain10             :	VAEntrypointVLD
      VAProfileHEVCMain10             :	VAEntrypointEncSlice
      VAProfileVP9Profile0            :	VAEntrypointVLD
      VAProfileVP9Profile2            :	VAEntrypointVLD

Vesktop doesn't run with those two, so I should comment them out to run it:

env = OZONE_PLATFORM,wayland
env = ELECTRON_OZONE_PLATFORM_HINT,wayland

Error from watching screenshare:

ERROR:ozone_image_backing.cc(329)] OzoneImageBacking::ProduceSkiaGanesh failed to create GL representation
ERROR:shared_image_manager.cc(230)] SharedImageManager::ProduceSkia: Trying to produce a Skia representation from an incompatible backing: OzoneImageBacking

Offline

#3 2024-09-22 16:21:32

Neroman
Member
Registered: 2024-09-13
Posts: 21

Re: Kinda confused with VA-API on Dual GPU. NVidia/Intel issues Hyprland

Update:
So i found that Hyprland somehow decided to use my Intel driver as main for compositing and it turns out that im forcing libva load NVIDIA VA-API driver while it uses Intel. https://github.com/elFarto/nvidia-vaapi … 1872903767
Idk what to do here. I think easy solution would be to install optimus-manager or something and manage what gpu to use in prime. DRM_PRIME and AQ_DRM_DEVICES didn't make it work.
Also found warning in mkinicpio -P:

sudo mkinitcpio -P | grep WARNING
==> WARNING: No module containing the symbol 'drm_privacy_screen_register' found in: 'drivers/platform'
==> WARNING: Possibly missing firmware for module: 'xhci_pci'
==> WARNING: consolefont: no font found in configuration
==> WARNING: No module containing the symbol 'drm_privacy_screen_register' found in: 'drivers/platform'
==> WARNING: Possibly missing firmware for module: 'xhci_pci'
==> WARNING: consolefont: no font found in configuration
==> WARNING: Possibly missing firmware for module: 'xhci_pci'
==> WARNING: consolefont: no font found in configuration
==> WARNING: Possibly missing firmware for module: 'ast'
==> WARNING: Possibly missing firmware for module: 'xhci_pci'
==> WARNING: consolefont: no font found in configuration
==> WARNING: Possibly missing firmware for module: 'aic94xx'
==> WARNING: Possibly missing firmware for module: 'bfa'
==> WARNING: Possibly missing firmware for module: 'qed'
==> WARNING: Possibly missing firmware for module: 'qla1280'
==> WARNING: Possibly missing firmware for module: 'qla2xxx'
==> WARNING: Possibly missing firmware for module: 'wd719x'

NVD_LOG=1 DRI_PRIME=1 vainfo

Trying display: wayland
vainfo: VA-API version: 1.22 (libva 2.22.0)
vainfo: Driver version: Intel iHD driver for Intel(R) Gen Graphics - 24.3.3 ()
vainfo: Supported profile and entrypoints
      VAProfileNone                   :	VAEntrypointVideoProc
      VAProfileNone                   :	VAEntrypointStats
      VAProfileMPEG2Simple            :	VAEntrypointVLD
      VAProfileMPEG2Simple            :	VAEntrypointEncSlice
      VAProfileMPEG2Main              :	VAEntrypointVLD
      VAProfileMPEG2Main              :	VAEntrypointEncSlice
      VAProfileH264Main               :	VAEntrypointVLD
      VAProfileH264Main               :	VAEntrypointEncSlice
      VAProfileH264Main               :	VAEntrypointFEI
      VAProfileH264Main               :	VAEntrypointEncSliceLP
      VAProfileH264High               :	VAEntrypointVLD
      VAProfileH264High               :	VAEntrypointEncSlice
      VAProfileH264High               :	VAEntrypointFEI
      VAProfileH264High               :	VAEntrypointEncSliceLP
      VAProfileVC1Simple              :	VAEntrypointVLD
      VAProfileVC1Main                :	VAEntrypointVLD
      VAProfileVC1Advanced            :	VAEntrypointVLD
      VAProfileJPEGBaseline           :	VAEntrypointVLD
      VAProfileJPEGBaseline           :	VAEntrypointEncPicture
      VAProfileH264ConstrainedBaseline:	VAEntrypointVLD
      VAProfileH264ConstrainedBaseline:	VAEntrypointEncSlice
      VAProfileH264ConstrainedBaseline:	VAEntrypointFEI
      VAProfileH264ConstrainedBaseline:	VAEntrypointEncSliceLP
      VAProfileVP8Version0_3          :	VAEntrypointVLD
      VAProfileVP8Version0_3          :	VAEntrypointEncSlice
      VAProfileHEVCMain               :	VAEntrypointVLD
      VAProfileHEVCMain               :	VAEntrypointEncSlice
      VAProfileHEVCMain               :	VAEntrypointFEI
      VAProfileHEVCMain10             :	VAEntrypointVLD
      VAProfileHEVCMain10             :	VAEntrypointEncSlice
      VAProfileVP9Profile0            :	VAEntrypointVLD
      VAProfileVP9Profile2            :	VAEntrypointVLD

DRM is set propely:

[roman@laptop ~]$ sudo cat /sys/module/nvidia_drm/parameters/modeset
Y

cat /etc/modprobe.d/nvidia.conf

options nvidia_drm modeset=1 fbdev=1

cat /etc/mkinitcpio.conf

# vim:set ft=sh
# MODULES
# The following modules are loaded before any boot hooks are
# run.  Advanced users may wish to specify all system modules
# in this array.  For instance:
#     MODULES=(usbhid xhci_hcd)
MODULES=(nvidia nvidia_modeset nvidia_uvm nvidia_drm i915)

Everything should work, but it just don't

Last edited by Neroman (2024-09-22 16:23:44)

Offline

#4 2024-09-22 16:43:20

Lone_Wolf
Administrator
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 12,877

Re: Kinda confused with VA-API on Dual GPU. NVidia/Intel issues Hyprland

cat /etc/modprobe.d/nvidia.conf

options nvidia_drm modeset=1 fbdev=1

Please add nvidia_drm.modeset=1 as a kernel parameter in your boot command line, there are plenty of cases where setting that option through modprobe.d is NOT enough.
(how to do that depends on your chosen bootloader).

The missing firmware lines from mkinitcpio are harmless .

consolefont messages are because you use a hook that requires configuration, drivers/platform messages are unknown to me.
I doubt they are related to the issue, if you want to look into them start a new thread for it
EDIT: you already did , https://bbs.archlinux.org/viewtopic.php?id=299651


There are 6 packages for vesktop in AUR, which are you using ?

As root (or with root rights) , run journalctl -b | curl -F 'file=@-' 0x0.st .
It will upload your journal to a public text-hosting server and output a link when it has done that..
Please post that link.

Last edited by Lone_Wolf (2024-09-22 16:45:37)


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.

clean chroot building not flexible enough ?
Try clean chroot manager by graysky

Offline

#5 2024-09-22 17:16:10

Neroman
Member
Registered: 2024-09-13
Posts: 21

Re: Kinda confused with VA-API on Dual GPU. NVidia/Intel issues Hyprland

Lone_Wolf wrote:

(how to do that depends on your chosen bootloader)

I'm using systemd-boot, so I need just add 'nvidia-drm.modeset=1' to loader config as an option, right?
Also I think that there is point to mention i'm using custom tkg kernel. Maybe some module is missing? Nvidia is loaded:

[roman@laptop ~]$ lsmod | grep nvidia
nvidia_drm            126976  14
nvidia_uvm           6733824  0
nvidia_modeset       1650688  6 nvidia_drm
video                  81920  2 i915,nvidia_modeset
nvidia              72564736  83 nvidia_uvm,nvidia_modeset

There are 6 packages for vesktop in AUR, which are you using ?

Currently I'm using default one: aur/vesktop 1.5.3-4 (+25 6.42) (Installed: 1.5.3-3)
Vesktop-bin didn't help. Also tried 'aur/vesktop_electron', but without configured env variables. I should try it again. Thanks for that!

run journalctl -b | curl -F 'file=@-' 0x0.st

https://0x0.st/XYKB.txt
Looks like driver issues, idk.

nvidia 0000:01:00.0: [drm] Cannot find any crtc or sizes

Last edited by Neroman (2024-09-22 17:21:28)

Offline

#6 2024-09-22 17:28:04

Neroman
Member
Registered: 2024-09-13
Posts: 21

Re: Kinda confused with VA-API on Dual GPU. NVidia/Intel issues Hyprland

Added 'nvidia-drm.modeset=1' to loader conf. Still same issue
NVD_LOG=1 vainfo

Trying display: wayland
        23.057285107 [883-883] ../nvidia-vaapi-driver-0.0.12/src/vabackend.c:2188       __vaDriverInit_1_0 Initialising NVIDIA VA-API Driver: 40
        23.057295422 [883-883] ../nvidia-vaapi-driver-0.0.12/src/vabackend.c:2197       __vaDriverInit_1_0 Now have 0 (0 max) instances
        23.057317680 [883-883] ../nvidia-vaapi-driver-0.0.12/src/vabackend.c:2223       __vaDriverInit_1_0 Selecting Direct backend
        23.076925375 [883-883] ../nvidia-vaapi-driver-0.0.12/src/backend-common.c:  31            isNvidiaDrmFd Invalid driver for DRM device: i915
        23.076934623 [883-883] ../nvidia-vaapi-driver-0.0.12/src/vabackend.c:2248       __vaDriverInit_1_0 Exporter failed
libva error: /usr/lib/dri/nvidia_drv_video.so init failed
vaInitialize failed with error code 1 (operation failed),exit

lsmod | grep drm

drm_buddy              24576  1 i915
drm_display_helper    229376  1 i915
cec                    73728  2 drm_display_helper,i915
nvidia_drm            126976  4
nvidia_modeset       1650688  3 nvidia_drm

Loader conf

sudo cat /boot/loader/entries/tkg-bmq.conf 

title Arch Linux TKG-BMQ
linux /vmlinuz-linux610-tkg-bmq
initrd /initramfs-linux610-tkg-bmq.img
options root=UUID=6c6621be-15ae-4755-a58a-0a6a0afae8d9 rw nvidia-drm.modeset=1
sudo cat /sys/module/nvidia_drm/parameters/modeset gives 'Y'

Last edited by Neroman (2024-09-22 17:28:41)

Offline

#7 2024-09-25 16:54:55

Neroman
Member
Registered: 2024-09-13
Posts: 21

Re: Kinda confused with VA-API on Dual GPU. NVidia/Intel issues Hyprland

Update: Still not working, even after reinstalling drivers and hyprland and different variables. I think I'll reinstall the system because Intel decided to be in charge hmm

Offline

#8 2024-09-26 17:35:19

Loskoss
Member
Registered: 2024-07-12
Posts: 1

Re: Kinda confused with VA-API on Dual GPU. NVidia/Intel issues Hyprland

Hello , in the hyprland wiki try this link

https://wiki.hyprland.org/Configuring/M … U/#general

Offline

Board footer

Powered by FluxBB