]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
drm/amdgpu: Fix SDMA engine reset with logical instance ID
authorJesse Zhang <jesse.zhang@amd.com>
Wed, 11 Jun 2025 07:02:09 +0000 (15:02 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 18 Jun 2025 16:19:18 +0000 (12:19 -0400)
commit5efa6217c239ed1ceec0f0414f9b6f6927387dfc
tree7bfbf8ccdf6259ac10ab4dba4142aaa5ed31b822
parent3f1e81ecb61923934bd11c3f5c1e10893574e607
drm/amdgpu: Fix SDMA engine reset with logical instance ID

This commit makes the following improvements to SDMA engine reset handling:

1. Clarifies in the function documentation that instance_id refers to a logical ID
2. Adds conversion from logical to physical instance ID before performing reset
   using GET_INST(SDMA0, instance_id) macro
3. Improves error messaging to indicate when a logical instance reset fails
4. Adds better code organization with blank lines for readability

The change ensures proper SDMA engine reset by using the correct physical
instance ID while maintaining the logical ID interface for callers.

V2: Remove harvest_config check and convert directly to physical instance (Lijo)

Suggested-by: Jonathan Kim <jonathan.kim@amd.com>
Signed-off-by: Jesse Zhang <Jesse.Zhang@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_sdma.c