D3D12 device creation fails on AMD Radeon RX 9070 XT (RDNA4): `ID3D12DeviceFactory::CreateDevice failed`, so Mesa d3d12/dzn fall back to llvmpipe

Đang mở
#42,301 1 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
5/5
Thời gian dự kiến
Hơn một tuần
Mức phù hợp với người mới
8/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
c, cpp, linux

Hướng nghiên cứu

Reproduce with the two commands in the report (vulkaninfo against dzn_icd.x86_64.json and glxinfo -B with GALLIUM_DRIVER=d3d12) and confirm the failure point at src/microsoft/vulkan/dzn_device.c:1155. Then read the dxgkrnl side behind the dxgkio_is_feature_enabled and dxgkio_query_adapter_info ioctls that return -22/-2 in dmesg, since adapter enumeration succeeds and only device creation fails inside the AMD UMD. Done looks like dzn and d3d12 exposing Microsoft Direct3D12 (AMD Radeon RX 9070 XT) instead of llvmpipe; this needs RDNA4 and WSL graphics-stack knowledge, so it is not a starter task.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

GPU needs-author-feedback wsl2
Windows Version

Microsoft Windows 11 Pro 26H2, build 10.0.26300.9974

WSL Version

WSL version: 3.0.5.0 Kernel version: 6.18.58.1-1 WSLg version: 1.0.79 MSRDC version: 1.2.7391 Direct3D version: 1.611.1-81528511 DXCore version: 10.0.26100.1-240331-1435.ge-release Windows version: 10.0.26300.9974

Are you using WSL 1, WSL 2, or WSLC?
  • WSL 2
  • WSL 1
  • WSLC
Kernel Version

6.18.58.1-microsoft-standard-WSL2

Distro Version

Fedora Linux 45 (official FedoraLinux-45 WSL image), Mesa 26.2.7 (mesa-dri-drivers, mesa-vulkan-drivers 26.2.7-1.fc45)

Other Software
  • GPU driver: AMD Radeon RX 9070 XT (PCI\VEN_1002&DEV_7550), driver 32.0.32015.16001 (dated 2026-11-10, the latest available)
  • CPU: AMD Ryzen 7 9800X3D (iGPU disabled)
  • Hardware-accelerated D3D12 and Vulkan both work normally on the Windows side (games run fine).
Repro Steps
  1. Fresh wsl --install FedoraLinux-45, then sudo dnf install mesa-dri-drivers mesa-vulkan-drivers vulkan-tools glx-utils
  2. Run VK_DRIVER_FILES=/usr/share/vulkan/icd.d/dzn_icd.x86_64.json vulkaninfo --summary
  3. Run GALLIUM_DRIVER=d3d12 glxinfo -B
Expected Behavior

The dzn Vulkan driver and the d3d12 Gallium driver expose Microsoft Direct3D12 (AMD Radeon RX 9070 XT).

Actual Behavior

D3D12 device creation fails, and both APIs end up on llvmpipe only.

Vulkan (dzn):

WARNING: dzn is not a conformant Vulkan implementation, testing use only.
Dropped Escape call with ulEscapeCode : 0x03007703
MESA: error: ID3D12DeviceFactory::CreateDevice failed
WARNING: [../src/microsoft/vulkan/dzn_device.c:1155] Code 0 : VK_ERROR_INITIALIZATION_FAILED
ERROR: [Loader Message] Code 0 : setup_loader_term_phys_devs: Call to 'vkEnumeratePhysicalDevices' in ICD /usr/lib64/libvulkan_dzn.so failed with error code -3

OpenGL (d3d12):

Dropped Escape call with ulEscapeCode : 0x03007703
Dropped Escape call with ulEscapeCode : 0x03007703
glx: failed to create drisw screen
X Error of failed request:  BadValue (integer parameter out of range for operation)
  Major opcode of failed request:  149 (GLX)
  Minor opcode of failed request:  24 (X_GLXCreateNewContext)

Without overrides, glxinfo -B and vulkaninfo --summary report only llvmpipe (LLVM 23.1.5, 256 bits).

dmesg, repeated on every attempt:

misc dxg: dxgk: dxgkio_is_feature_enabled: Ioctl failed: -22
misc dxg: dxgk: dxgkio_query_adapter_info: Ioctl failed: -22
misc dxg: dxgk: dxgkio_query_adapter_info: Ioctl failed: -22
misc dxg: dxgk: dxgkio_query_adapter_info: Ioctl failed: -22
misc dxg: dxgk: dxgkio_query_adapter_info: Ioctl failed: -2
Diagnostic Logs

What strace shows: libdxcore.so loads, /dev/dxg opens, libd3d12core.so loads, and the AMD user-mode driver loads from the driver store:

openat(AT_FDCWD, "/usr/lib/wsl/lib/libdxcore.so", O_RDONLY|O_CLOEXEC) = 4
openat(AT_FDCWD, "/dev/dxg", O_RDONLY|O_CLOEXEC) = 4
openat(AT_FDCWD, "/usr/lib/wsl/lib/libd3d12core.so", O_RDONLY|O_CLOEXEC) = 6
openat(AT_FDCWD, "/usr/lib/wsl/drivers/u0206030.inf_amd64_7ca820b1ce728070/B026778/amdxc64.so", O_RDONLY|O_CLOEXEC) = 6

After that, CreateDevice fails. So adapter enumeration and loading the user-mode driver both succeed, and the failure happens inside device creation in the AMD UMD / D3D12 layer.

Already ruled out:

  • Library paths: /usr/lib/wsl/lib is in the ldconfig cache, and libd3d12.so, libd3d12core.so and libdxcore.so all resolve.
  • Adapter selection: MESA_D3D12_DEFAULT_ADAPTER_NAME=AMD gives the same failure.
  • Indirect display adapter: The system also has a "Meta Virtual Monitor" indirect display adapter (ROOT\DISPLAY\0000). Disabling it, then wsl --shutdown and retesting gives the identical failure and identical dmesg output.
  • WSL version: 3.0.5 is the latest release.

Possibly related: #41733 (RX 9070 XT, D3D12 VA-API exposes no decode profiles). That report also shows dropped AMD escape calls, which suggests a wider RDNA4 UMD ↔ dxgkrnl compatibility problem.

I'm happy to collect logs with collect-wsl-logs.ps1 or run any other diagnostics.

Ngôn ngữ chính
C++
Star
34.4k
Fork
1.9k
Merge trung bình
1 ngày 23 giờ
Pull request đã merge (30 ngày)
166

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của microsoft/WSL

Tất cả issue của microsoft/WSL

Issue tương tự

Thêm issue về C++

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.