<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
comment inline.</div>
<hr tabindex="-1" style="display:inline-block; width:98%">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" color="#000000" style="font-size:11pt"><b>From:</b> amd-gfx <amd-gfx-bounces@lists.freedesktop.org> on behalf of chen gong <curry.gong@amd.com><br>
<b>Sent:</b> Monday, October 14, 2019 10:57 AM<br>
<b>To:</b> amd-gfx@lists.freedesktop.org <amd-gfx@lists.freedesktop.org><br>
<b>Cc:</b> Gong, Curry <Curry.Gong@amd.com><br>
<b>Subject:</b> [PATCH] drm/amdgpu: No need to check gfxoff status after enable gfxoff feature</font>
<div> </div>
</div>
<div class="BodyFragment"><font size="2"><span style="font-size:11pt">
<div class="PlainText">smu_send_smc_msg(smu, SMU_MSG_AllowGfxOff) Just turn on a switch.<br>
<br>
As to when GPU get into "GFXoff" will be up to drawing load.<br>
<br>
So we can not sure which state GPU should be in after enable gfxoff<br>
feature.<br>
<br>
Signed-off-by: chen gong <curry.gong@amd.com><br>
---<br>
 drivers/gpu/drm/amd/powerplay/smu_v12_0.c | 9 ---------<br>
 1 file changed, 9 deletions(-)<br>
<br>
diff --git a/drivers/gpu/drm/amd/powerplay/smu_v12_0.c b/drivers/gpu/drm/amd/powerplay/smu_v12_0.c<br>
index c9691d0..cac4269 100644<br>
--- a/drivers/gpu/drm/amd/powerplay/smu_v12_0.c<br>
+++ b/drivers/gpu/drm/amd/powerplay/smu_v12_0.c<br>
@@ -244,15 +244,6 @@ static int smu_v12_0_gfx_off_control(struct smu_context *smu, bool enable)<br>
         if (enable) {<br>
                 ret = smu_send_smc_msg(smu, SMU_MSG_AllowGfxOff);<br>
 <br>
-               /* confirm gfx is back to "off" state, timeout is 5 seconds */<br>
-               while (!(smu_v12_0_get_gfxoff_status(smu) == 0)) {<br>
-                       msleep(10);<br>
-                       timeout--;</div>
<div class="PlainText">[kevin]:</div>
<div class="PlainText">the varible of "timeout" is not used after this patch, please remove it together.</div>
<div class="PlainText">after fixed.</div>
<div class="PlainText">Reviewed-by: Kevin Wang <kevin1.wang@amd.com></div>
<div class="PlainText"><br>
</div>
<div class="PlainText">-                       if (timeout == 0) {<br>
-                               DRM_ERROR("enable gfxoff timeout and failed!\n");<br>
-                               break;<br>
-                       }<br>
-               }<br>
         } else {<br>
                 ret = smu_send_smc_msg(smu, SMU_MSG_DisallowGfxOff);<br>
 <br>
-- <br>
2.7.4<br>
<br>
_______________________________________________<br>
amd-gfx mailing list<br>
amd-gfx@lists.freedesktop.org<br>
<a href="https://lists.freedesktop.org/mailman/listinfo/amd-gfx">https://lists.freedesktop.org/mailman/listinfo/amd-gfx</a></div>
</span></font></div>
</body>
</html>