mesa/src/amd/drm-shim
jesse.zhang 56d758d321 amd: Add user queue HQD count to hw_ip info
Add a new field userq_num_hqds to drm_amdgpu_info_hw_ip to expose the
number of available hardware queue descriptors (HQDs) for user queues.
This allows userspace to query the maximum number of user queues that
can be created for a particular IP block.

the patch link in driver side:
https://lists.freedesktop.org/archives/amd-gfx/2025-June/126686.html

v2: we should also put userq_num_hqds into radeon_info and
print it where other fields are printed. (Marek Olšák)

v3: rename num_userqs to num_queue_slots
    and add print log in ac_print_gpu_info. (Marek Olšák)
v4: rename userq_num_hqds to userq_num_slots in hw_ip_info,
    and update the hw information (Marek Olšák)

Signed-off-by: Jesse Zhang <Jesse.Zhang@amd.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35850>
2025-07-08 10:17:51 +00:00
..
amdgpu_devices.c amd: Add user queue HQD count to hw_ip info 2025-07-08 10:17:51 +00:00
amdgpu_devices.h amd/drm-shim: move device list to external file 2023-05-15 11:32:06 +00:00
amdgpu_dump_states.c amd: Add user queue HQD count to hw_ip info 2025-07-08 10:17:51 +00:00
amdgpu_noop_drm_shim.c amd/drm-shim: move device list to external file 2023-05-15 11:32:06 +00:00
meson.build build: pass licensing information in SPDX form 2024-06-29 12:42:49 -07:00
radeon_noop_drm_shim.c amd: Use align64 instead of ALIGN for 64 bit value parameter 2024-01-03 22:02:17 +00:00
README.md amd/drm-shim: update README about which file to modify 2023-05-19 06:59:30 +00:00

radeon_noop backend

This implements the minimum of the radeon kernel driver in order to make shader-db work. The submit ioctl is stubbed out to not execute anything.

Export MESA_LOADER_DRIVER_OVERRIDE=r300 LD_PRELOAD=$prefix/lib/libradeon_noop_drm_shim.so. (or r600 for r600-class HW)

By default, rv515 is exposed. The chip can be selected an environment variable like RADEON_GPU_ID=CAYMAN or RADEON_GPU_ID=0x6740.

amdgpu_noop backend

This implements the minimum of the amdgpu kernel driver. The submit ioctl is stubbed out to not execute anything.

Export LD_PRELOAD=$prefix/lib/libamdgpu_noop_drm_shim.so.

To specify the device to expose, set the environment variable AMDGPU_GPU_ID to

  • renoir to expose a CHIP_RENOIR device
  • raven to expose a CHIP_RAVEN device
  • stoney to expose a CHIP_STONEY device

Further names follow the CHIP_* enum values. By default, the CHIP_RENOIR device is exposed.

To add a new device, amdgpu_devices.c needs to be modified. amdgpu_dump_states can be used to dump the relevant states from a real device.