NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

kern/58710: amdgpu kernel bug -- modesetting driver GL Rendering failure



>Number:         58710
>Category:       kern
>Synopsis:       amdgpu kernel bug -- modesetting driver GL Rendering failure
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    kern-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon Sep 30 02:15:00 +0000 2024
>Originator:     David
>Release:        NetBSD 10.0 amd64
>Organization:
>Environment:
NetBSD desktop.local 10.0 NetBSD 10.0 (MYKERNEL) #0: Sat Sep  7 22:38:21 AEST 2024  dave@desktop.local:/usr/src/sys/arch/amd64/compile/MYKERNEL amd64
>Description:
I've rebuilt the kernel to get the system to support amdgpu. The only modifications made were uncommenting the 2 amdgpu lines and commenting out the 2 radeon lines. Additionally I uncommended the DEBUG, DIAGNOSTIC, and LOCKDEBUG lines.

My GPU is: AMD Radeon RX 570 Series

Any GL rendered apps report errors when launching:

Firefox:

```
~ $ firefox
Crash Annotation GraphicsCriticalError: |[0][GFX1-]: glxtest: DRM device has no render node (t=0.462674) [GFX1-]: glxtest: DRM device has no render node
Crash Annotation GraphicsCriticalError: |[0][GFX1-]: glxtest: DRM device has no render node (t=0.462674) |[1][GFX1-]: glxtest: Cannot find DRM device (t=0.462784) [GFX1-]: glxtest: Cannot find DRM device
ATTENTION: default value of option mesa_glthread overridden by environment.
ATTENTION: default value of option mesa_glthread overridden by environment.
amdgpu: os_same_file_description couldn't determine if two DRM fds reference the same file description.
If they do, bad things may happen!
ac_rtld error: !data || data->d_size != shdr->sh_size
LLVM failed to upload shader
ac_rtld error: !data || data->d_size != shdr->sh_size
LLVM failed to upload shader
ac_rtld error: !data || data->d_size != shdr->sh_size
LLVM failed to upload shader
EE ../src/gallium/drivers/radeonsi/si_state_shaders.c:2226 si_build_shader_variant - Failed to build shader variant (type=0)
ac_rtld error: !data || data->d_size != shdr->sh_size
LLVM failed to upload shader
EE ../src/gallium/drivers/radeonsi/si_state_shaders.c:2226 si_build_shader_variant - Failed to build shader variant (type=0)
ac_rtld error: !data || data->d_size != shdr->sh_size
LLVM failed to upload shader
EE ../src/gallium/drivers/radeonsi/si_state_shaders.c:2226 si_build_shader_variant - Failed to build shader variant (type=0)
ac_rtld error: !data || data->d_size != shdr->sh_size
LLVM failed to upload shader
EE ../src/gallium/drivers/radeonsi/si_state_shaders.c:2226 si_build_shader_variant - Failed to build shader variant (type=0)
ac_rtld error: !data || data->d_size != shdr->sh_size
LLVM failed to upload shader
EE ../src/gallium/drivers/radeonsi/si_state_shaders.c:2226 si_build_shader_variant - Failed to build shader variant (type=0)
ac_rtld error: !data || data->d_size != shdr->sh_size
LLVM failed to upload shader
EE ../src/gallium/drivers/radeonsi/si_state_shaders.c:2226 si_build_shader_variant - Failed to build shader variant (type=0)
ac_rtld error: !data || data->d_size != shdr->sh_size
LLVM failed to upload shader
EE ../src/gallium/drivers/radeonsi/si_state_shaders.c:2226 si_build_shader_variant - Failed to build shader variant (type=0)
ac_rtld error: !data || data->d_size != shdr->sh_size
LLVM failed to upload shader
EE ../src/gallium/drivers/radeonsi/si_state_shaders.c:2226 si_build_shader_variant - Failed to build shader variant (type=0)
ac_rtld error: !data || data->d_size != shdr->sh_size
LLVM failed to upload shader
EE ../src/gallium/drivers/radeonsi/si_state_shaders.c:2226 si_build_shader_variant - Failed to build shader variant (type=0)
ac_rtld error: !data || data->d_size != shdr->sh_size
LLVM failed to upload shader
EE ../src/gallium/drivers/radeonsi/si_state_shaders.c:2226 si_build_shader_variant - Failed to build shader variant (type=0)
ac_rtld error: !data || data->d_size != shdr->sh_size
LLVM failed to upload shader
EE ../src/gallium/drivers/radeonsi/si_state_shaders.c:2226 si_build_shader_variant - Failed to build shader variant (type=0)
ac_rtld error: !data || data->d_size != shdr->sh_size
LLVM failed to upload shader
EE ../src/gallium/drivers/radeonsi/si_state_shaders.c:2226 si_build_shader_variant - Failed to build shader variant (type=0)
ac_rtld error: !data || data->d_size != shdr->sh_size
LLVM failed to upload shader
```

```
~ $ firefox --MOZ_LOG=Dmabuf:5
Crash Annotation GraphicsCriticalError: |[0][GFX1-]: glxtest: DRM device has no render node (t=0.520564) [GFX1-]: glxtest: DRM device has no render node
Crash Annotation GraphicsCriticalError: |[0][GFX1-]: glxtest: DRM device has no render node (t=0.520564) |[1][GFX1-]: glxtest: Cannot find DRM device (t=0.520684) [GFX1-]: glxtest: Cannot find DRM device
[Parent 13098: Main Thread]: D/Dmabuf DMABufDevice::Configure()
[Parent 13098: Main Thread]: D/Dmabuf Loading DMABuf system library libgbm.so.1 ...
[Parent 13098: Main Thread]: D/Dmabuf Failed to load libdrm.so.2, dmabuf isn't available.
[Parent 13098: Main Thread]: D/Dmabuf GbmLib is not available!
ATTENTION: default value of option mesa_glthread overridden by environment.
ATTENTION: default value of option mesa_glthread overridden by environment.
amdgpu: os_same_file_description couldn't determine if two DRM fds reference the same file description.
If they do, bad things may happen!
```


GLXINFO:

```
~ $ glxinfo -B
name of display: :0
display: :0  screen: 0
direct rendering: Yes
Extended renderer info (GLX_MESA_query_renderer):
    Vendor: X.Org (0x1002)
    Device: AMD Radeon RX 570 Series (POLARIS10, DRM 3.36.0, 10.0, LLVM 13.0.0) (0x67df)
    Version: 19.1.17
    Accelerated: yes
    Video memory: 4096MB
    Unified memory: no
    Preferred profile: core (0x1)
    Max core profile version: 4.5
    Max compat profile version: 4.5
    Max GLES1 profile version: 1.1
    Max GLES[23] profile version: 3.2
Memory info (GL_ATI_meminfo):
    VBO free memory - total: 3917 MB, largest block: 3917 MB
    VBO free aux. memory - total: 4068 MB, largest block: 4068 MB
    Texture free memory - total: 3917 MB, largest block: 3917 MB
    Texture free aux. memory - total: 4068 MB, largest block: 4068 MB
    Renderbuffer free memory - total: 3917 MB, largest block: 3917 MB
    Renderbuffer free aux. memory - total: 4068 MB, largest block: 4068 MB
Memory info (GL_NVX_gpu_memory_info):
    Dedicated video memory: 4096 MB
    Total available memory: 8192 MB
    Currently available dedicated video memory: 3917 MB
OpenGL vendor string: X.Org
OpenGL renderer string: AMD Radeon RX 570 Series (POLARIS10, DRM 3.36.0, 10.0, LLVM 13.0.0)
OpenGL core profile version string: 4.5 (Core Profile) Mesa 19.1.17
OpenGL core profile shading language version string: 4.50
OpenGL core profile context flags: (none)
OpenGL core profile profile mask: core profile

OpenGL version string: 4.5 (Compatibility Profile) Mesa 19.1.17
OpenGL shading language version string: 4.50
OpenGL context flags: (none)
OpenGL profile mask: compatibility profile

OpenGL ES profile version string: OpenGL ES 3.2 Mesa 19.1.17
OpenGL ES profile shading language version string: OpenGL ES GLSL ES 3.20
```

/etc/xorg.conf :

```
Section "Device"
        Identifier "Card0"
        Driver "modesetting"
EndSection
```


>How-To-Repeat:
1. Have an AMD Radeon RX 570 Series GPU.
2. Recompile kernel with both amdgpu lines uncommented and both radeon lines commented out.
3. Set modesetting drive in xorg.conf
4. Have Firefox installed
5. Start graphical xorg session using startx
6. Open Firefox, observe. >> Screenshot: https://0x0.st/XwYi.png
>Fix:



Home | Main Index | Thread Index | Old Index