drm/amd/pm: Add waiting for response of mode-reset message for yellow carp
Subsystems (3)
PATCH 1/1 drm/amd/pm: Add waiting for response of mode-reset message for yellow carp
Remove mdelay process and use smu_cmn_send_smc_msg_with_param to send mode-reset message to SMC.
--- drivers/gpu/drm/amd/pm/swsmu/smu13/yellow_carp_ppt.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-)
drivers/gpu/drm/amd/pm/swsmu/smu13/yellow_carp_ppt.c +3 -7
@@ -298,13 +298,9 @@ static int yellow_carp_mode_reset(struct smu_context *smu, int type)if (index <0 )return index == -EACCES ?0 : index; -mutex_lock (&smu->message_lock); - - ret =smu_cmn_send_msg_without_waiting (smu, (uint16_t )index, type); - -mutex_unlock (&smu->message_lock); - -mdelay (10 ); + ret =smu_cmn_send_smc_msg_with_param (smu, (uint16_t )index, type,NULL ); +if (ret) +dev_err (smu->adev->dev,"Failed to mode reset!\n" );return ret; }
Signature · 6 lines
2.25.1 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx
[AMD Official Use Only]
Quoted 46 lines
-----Original Message-----
From: amd-gfx <[email protected]> On Behalf Of Aaron Liu
Sent: Tuesday, July 13, 2021 3:01 PM
To: [email protected]
Cc: Deucher, Alexander <[email protected]>; Huang, Ray <[email protected]>; Liu, Aaron <[email protected]>
Subject: [PATCH] drm/amd/pm: Add waiting for response of mode-reset message for yellow carpRemove mdelay process and use
smu_cmn_send_smc_msg_with_paramto send mode-reset message to SMC.Signed-off-by Aaron Liu <[email protected]>--- drivers/gpu/drm/amd/pm/swsmu/smu13/yellow_carp_ppt.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-)drivers/gpu/drm/amd/pm/swsmu/smu13/yellow_carp_ppt.c +3
-7@@ -298,13 +298,9 @@ static int yellow_carp_mode_reset(struct smu_context *smu, int type) if (index < 0) return index == -EACCES ? 0 : index; -mutex_lock (&smu->message_lock); - - ret =smu_cmn_send_msg_without_waiting (smu, (uint16_t )index, type); - -mutex_unlock (&smu->message_lock); - -mdelay (10 ); + ret =smu_cmn_send_smc_msg_with_param (smu, (uint16_t )index, type,NULL ); +if (ret) +dev_err (smu->adev->dev,"Failed to mode reset!\n" );return ret;
}
--
2.25.1
Quoted 10 lines
_______________________________________________
amd-gfx mailing list
[email protected]
https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.
freedesktop.org%2Fmailman%2Flistinfo%2Famd- gfx&data=04%7C01%7Cevan.quan%40amd.com%7C1045fee1435a4b49d 1ae08d945cc0427%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C63 7617564811709038%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMD AiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&sdata= FSmq1fObJ5x2Yl86ZWsGpr7SZPju6o4CZYyPp2xBZOs%3D&reserved=0
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Quoted 4 lines · Aaron
Remove mdelay process and use
smu_cmn_send_smc_msg_with_paramto send mode-reset message to SMC.Signed-off-by Aaron Liu <[email protected]>
Quoted 28 lines
--- drivers/gpu/drm/amd/pm/swsmu/smu13/yellow_carp_ppt.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-)drivers/gpu/drm/amd/pm/swsmu/smu13/yellow_carp_ppt.c +3
-7@@ -298,13 +298,9 @@ static int yellow_carp_mode_reset(struct smu_context *smu, int type)if (index <0 )return index == -EACCES ?0 : index; -mutex_lock (&smu->message_lock); - - ret =smu_cmn_send_msg_without_waiting (smu, (uint16_t )index, type); - -mutex_unlock (&smu->message_lock); - -mdelay (10 ); + ret =smu_cmn_send_smc_msg_with_param (smu, (uint16_t )index, type,NULL ); +if (ret) +dev_err (smu->adev->dev,"Failed to mode reset!\n" );return ret; }Signature · 1 line
2.25.1
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx