Re: [RFC v2 13/15] drm/amdgpu: walk IP blocks in reverse order when shutdown

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

 



On 1/12/2025 19:42, Jiang Liu wrote:
Walk IP blocks in reverse order in function amdgpu_device_ip_fini_early
and amdgpu_device_smu_fini_early, to keep consistence with other finish
functions.

Signed-off-by: Jiang Liu <gerry@xxxxxxxxxxxxxxxxx>
Reviewed-by: Mario Limonciello <mario.limonciello@xxxxxxx>
---
  drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 4 ++--
  1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
index af356226fbca..a1501344f336 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
@@ -3358,7 +3358,7 @@ static void amdgpu_device_smu_fini_early(struct amdgpu_device *adev)
  	if (amdgpu_ip_version(adev, GC_HWIP, 0) > IP_VERSION(9, 0, 0))
  		return;
- amdgpu_for_each_ip_block(adev, ip_block) {
+	amdgpu_for_each_ip_block_reverse(adev, ip_block) {
  		if (amdgpu_ip_block_state(ip_block) < AMDGPU_IP_STATE_HW)
  			continue;
  		if (ip_block->version->type == AMD_IP_BLOCK_TYPE_SMC) {
@@ -3373,7 +3373,7 @@ static int amdgpu_device_ip_fini_early(struct amdgpu_device *adev)
  	int r;
  	struct amdgpu_ip_block *ip_block;
- amdgpu_for_each_ip_block(adev, ip_block) {
+	amdgpu_for_each_ip_block_reverse(adev, ip_block) {
  		if (!ip_block->version->funcs->early_fini)
  			continue;




[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux