Skip to contentSkip to conversation

drm/amd/powerplay:clean up the residual mutex for smu_hw_init

PATCH In review Prike Liang 2 participants 2 messages Jun 25, 2019 – Jun 26, 2019 1 message not in the archive

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 drm/amd/powerplay:clean up the residual mutex for smu_hw_init

The mutex for procting SMU during hw_init was removed as system will be deadlock when smu_populate_umd_state_clk try get SMU mutex. Therefore need remove the residual mutex from failed path.

Change-Id Id8019c01b9496c067efda4817a46983e4da3b6e4
---
 drivers/gpu/drm/amd/powerplay/amdgpu_smu.c | 1 -
 1 file changed, 1 deletion(-)
drivers/gpu/drm/amd/powerplay/amdgpu_smu.c +0 -1
index f61ecbf..fe83c5e 100644
@@ -1044,7 +1044,6 @@ static int smu_hw_init(void *handle)
 	return 0;
 
 failed:
-	mutex_unlock(&smu->mutex);
 	return ret;
 }
 
Signature · 6 lines
2.7.4

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

A message that is not in the archive (sent off-list or not yet received): 1561448595-32319-1-git-send-email-Prike.Liang-5C7GfCeVMHo@public.gmane.org

Reviewed-by
#2 lore raw
Quoted 15 lines · Prike Liang

The mutex for procting SMU during hw_init was removed as system will be deadlock when smu_populate_umd_state_clk try get SMU mutex. Therefore need remove the residual mutex from failed path.

Change-Id Id8019c01b9496c067efda4817a46983e4da3b6e4
---
  drivers/gpu/drm/amd/powerplay/amdgpu_smu.c | 1 -
  1 file changed, 1 deletion(-)
drivers/gpu/drm/amd/powerplay/amdgpu_smu.c +0 -0
index f61ecbf..fe83c5e 100644

drivers/gpu/drm/amd/powerplay/amdgpu_smu.c static int smu_hw_init(void *handle) · line 1049

Quoted 7 lines
drivers/gpu/drm/amd/powerplay/amdgpu_smu.c +0 -1
@@ -1044,7 +1044,6 @@ static int smu_hw_init(void *handle)
  	return 0;
 
  failed:
-	mutex_unlock(&smu->mutex);
  	return ret;
  }
 

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx