Score:2

eglinfo ACCEL_WORKING query results in permission denied

cn flag

When I execute eglinfo from the mesa-utils package, I get failures:

$ eglinfo
...
GBM platform:
amdgpu_device_initialize: amdgpu_query_info(ACCEL_WORKING) failed (-13)
amdgpu: amdgpu_device_initialize failed.
amdgpu_device_initialize: amdgpu_query_info(ACCEL_WORKING) failed (-13)
amdgpu: amdgpu_device_initialize failed.
...

I have traced the amdgpu_query_info() to libdrm in the file amdgpu/amdgpu_gpu_info.c

The drmCommandWrite() fails with errno 13: Permission Denied.

Initially I thought this was trivial to fix, as I noticed that the devices in /dev/dri/* had group ownership video and render. But after making the user part of these groups, and rebooting, the error is still present.

Why does drmCommandWrite() fail with denied permissions? I have no such issue when running the integrated graphics and the iris driver.

$ inxi -G
Graphics:
  Device-1: AMD Ellesmere [Radeon RX 470/480/570/570X/580/580X/590]
    driver: amdgpu v: kernel
  Display: wayland server: X.org v: 1.21.1.4 with: Xwayland v: 22.1.3
    compositor: gnome-shell v: 43.1 driver: X: loaded: modesetting
    unloaded: fbdev,vesa gpu: amdgpu resolution: 1920x1080~60Hz
  OpenGL: renderer: AMD Radeon RX 580 Series (polaris10 LLVM 15.0.2 DRM
    3.49 6.1.6-060106-generic) v: 4.6 Mesa 22.2.1

OS: Ubuntu 22.10

update

The permission denied error goes away when running as root.

A relevant comment on a gitlab issue explains that the display server should have authenticated access to /dev/dri/card0 first.

I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.