20.04.3: libva2 fails under Wayland (wl_drm@22: error 0: authenticate failed)

Bug #1961484 reported by Andrei Borzenkov
48
This bug affects 9 people
Affects Status Importance Assigned to Milestone
libva (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

In current 20.04.3 libva2 fails to authenticate connection to Wayland composer. This may be related to update of Mesa to 21.2.6. Any program using libva2 fails with

bor@bor-Latitude-E5450:~$ vainfo
wl_drm@7: error 0: authenticate failed
VA error: wayland: Wayland roundtrip error: Protocol error (errno 71)
libva info: VA-API version 1.7.0
libva error: vaGetDriverNameByIndex() failed with invalid VADisplay, driver_name = (null)
vaInitialize failed with error code 3 (invalid VADisplay),exit
bor@bor-Latitude-E5450:~$

This is fixed in libva upstream in pull request https://github.com/intel/libva/pull/476

I verified that upstream libva correctly works:

bor@bor-Latitude-E5450:~/src/intel/libva-utils$ ./vainfo/vainfo
libva info: VA-API version 1.15.0
libva info: Trying to open /home/bor/pkg/lib/dri/iHD_drv_video.so
libva info: va_openDriver() returns -1
libva info: Trying to open /home/bor/pkg/lib/dri/i965_drv_video.so
libva info: Found init function __vaDriverInit_1_6
libva info: va_openDriver() returns 0
vainfo: VA-API version: 1.15 (libva 2.15.0.pre1)
vainfo: Driver version: Intel i965 driver for Intel(R) Broadwell - 2.4.0
vainfo: Supported profile and entrypoints
      VAProfileMPEG2Simple : VAEntrypointVLD
      VAProfileMPEG2Simple : VAEntrypointEncSlice
      VAProfileMPEG2Main : VAEntrypointVLD
      VAProfileMPEG2Main : VAEntrypointEncSlice
      VAProfileH264ConstrainedBaseline: VAEntrypointVLD
      VAProfileH264ConstrainedBaseline: VAEntrypointEncSlice
      VAProfileH264Main : VAEntrypointVLD
      VAProfileH264Main : VAEntrypointEncSlice
      VAProfileH264High : VAEntrypointVLD
      VAProfileH264High : VAEntrypointEncSlice
      VAProfileH264MultiviewHigh : VAEntrypointVLD
      VAProfileH264MultiviewHigh : VAEntrypointEncSlice
      VAProfileH264StereoHigh : VAEntrypointVLD
      VAProfileH264StereoHigh : VAEntrypointEncSlice
      VAProfileVC1Simple : VAEntrypointVLD
      VAProfileVC1Main : VAEntrypointVLD
      VAProfileVC1Advanced : VAEntrypointVLD
      VAProfileNone : VAEntrypointVideoProc
      VAProfileJPEGBaseline : VAEntrypointVLD
      VAProfileVP8Version0_3 : VAEntrypointVLD
bor@bor-Latitude-E5450:~/src/intel/libva-utils$

With *only* commit 283f776a9649dcef58b47958c1269499adfa1cd4 reverted

bor@bor-Latitude-E5450:~/src/intel/libva-utils$ ./vainfo/vainfo
wl_drm@7: error 0: authenticate failed
VA error: wayland: Wayland roundtrip error: Protocol error (errno 71)
libva info: VA-API version 1.15.0
libva error: vaGetDriverNameByIndex() failed with invalid VADisplay, driver_name = (null)
vaInitialize failed with error code 3 (invalid VADisplay),exit
bor@bor-Latitude-E5450:~/src/intel/libva-utils$

Please update libva in 20.04.3 to match Mesa. This bug affects any application that is trying to use VAAPI for hardware acceleration.

ProblemType: Bug
DistroRelease: Ubuntu 20.04
Package: libva2 2.7.0-2
ProcVersionSignature: Ubuntu 5.13.0-30.33~20.04.1-lowlatency 5.13.19
Uname: Linux 5.13.0-30-lowlatency x86_64
ApportVersion: 2.20.11-0ubuntu27.21
Architecture: amd64
CasperMD5CheckResult: skip
CurrentDesktop: ubuntu:GNOME
Date: Sat Feb 19 19:16:15 2022
DistributionChannelDescriptor:
 # This is a distribution channel descriptor
 # For more information see http://wiki.ubuntu.com/DistributionChannelDescriptor
 canonical-oem-somerville-trusty-amd64-20140620-0
InstallationDate: Installed on 2015-07-02 (2424 days ago)
InstallationMedia: Ubuntu 14.04 "Trusty" - Build amd64 LIVE Binary 20140620-04:25
ProcEnviron:
 TERM=xterm-256color
 PATH=(custom, no user)
 XDG_RUNTIME_DIR=<set>
 LANG=ru_RU.UTF-8
 SHELL=/bin/bash
SourcePackage: libva
UpgradeStatus: No upgrade log present (probably fresh install)

Revision history for this message
Andrei Borzenkov (arvidjaar-s) wrote :
Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in libva (Ubuntu):
status: New → Confirmed
Revision history for this message
Rijnhard Hessel (rijnhard) wrote (last edit ):

Same issue
Ubuntu 20.04.4 LTS
Kernel - 5.4.0-150-generic

libva2 - 2.7.0-2 (api version 1.7.0)

App causing issues - kodi wayland from the team kodi ppa.
Mpv will likely also do this.

AMD A10-7800 Radeon R7
libdrm-amdgpu1 - 2.4.107-8ubuntu1~20.04.2

Also seeing a lot of complaints about this suddenly on the kodi github issue tracker

Revision history for this message
Wolfgang Schupp (wsnipex) wrote :

for anyone interested: I've updated my vaapi PPA with libva 2.14: https://launchpad.net/~wsnipex/+archive/ubuntu/vaapi/+packages
Simple backport from jammy, without any changes

Revision history for this message
Davide Matarese (minkiux) wrote (last edit ):

Does someone know any workaround or an ETA for the issue to be solved?

Revision history for this message
Hernan Gonzalez (nuco) wrote :

As a workarround for MPV i set hwdec=drm in /etc/mpv/mpv.conf

Revision history for this message
Zhihao Wang (wangzhihao9) wrote :

In my test, these packages in PPA fixed the problem.
add PPA and update & upgrade, the issue disappear.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.