<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">
<p style="font-family:Arial;font-size:10pt;color:#0078D7;margin:15pt;" align="Left">
[AMD Official Use Only - Internal Distribution Only]<br>
</p>
<br>
<div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
fine for me.</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Reviewed-by: Kevin Wang <kevin1.wang@amd.com></div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Best Regards,<br>
Kevin</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 Kenneth Feng <kenneth.feng@amd.com><br>
<b>Sent:</b> Thursday, January 9, 2020 9:53 AM<br>
<b>To:</b> amd-gfx@lists.freedesktop.org <amd-gfx@lists.freedesktop.org><br>
<b>Cc:</b> Quan, Evan <Evan.Quan@amd.com>; Feng, Kenneth <Kenneth.Feng@amd.com><br>
<b>Subject:</b> [PATCH] drm/amd/powerplay: sw ctf for arcturus</font>
<div> </div>
</div>
<div class="BodyFragment"><font size="2"><span style="font-size:11pt">
<div class="PlainText">software ctf implementation on arcturs.<br>
has been verified on the system by setting a fake software ctf<br>
temperature limit like 40 degrees centigrade.<br>
then the interrupt is triggered from ih ring and<br>
the warning can be observed from dmesg.<br>
<br>
Signed-off-by: Kenneth Feng <kenneth.feng@amd.com><br>
---<br>
 drivers/gpu/drm/amd/powerplay/arcturus_ppt.c | 6 ++++--<br>
 1 file changed, 4 insertions(+), 2 deletions(-)<br>
<br>
diff --git a/drivers/gpu/drm/amd/powerplay/arcturus_ppt.c b/drivers/gpu/drm/amd/powerplay/arcturus_ppt.c<br>
index 50b317f..330d5f4 100644<br>
--- a/drivers/gpu/drm/amd/powerplay/arcturus_ppt.c<br>
+++ b/drivers/gpu/drm/amd/powerplay/arcturus_ppt.c<br>
@@ -846,11 +846,13 @@ static int arcturus_get_thermal_temperature_range(struct smu_context *smu,<br>
                                                 struct smu_temperature_range *range)<br>
 {<br>
         PPTable_t *pptable = smu->smu_table.driver_pptable;<br>
+       struct smu_table_context *table_context = &smu->smu_table;<br>
+       struct smu_11_0_powerplay_table *powerplay_table = table_context->power_play_table;<br>
 <br>
-       if (!range)<br>
+       if (!range || !powerplay_table)<br>
                 return -EINVAL;<br>
 <br>
-       range->max = pptable->TedgeLimit *<br>
+       range->max = powerplay_table->software_shutdown_temp *<br>
                 SMU_TEMPERATURE_UNITS_PER_CENTIGRADES;<br>
         range->edge_emergency_max = (pptable->TedgeLimit + CTF_OFFSET_EDGE) *<br>
                 SMU_TEMPERATURE_UNITS_PER_CENTIGRADES;<br>
-- <br>
2.7.4<br>
<br>
_______________________________________________<br>
amd-gfx mailing list<br>
amd-gfx@lists.freedesktop.org<br>
<a href="https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.freedesktop.org%2Fmailman%2Flistinfo%2Famd-gfx&amp;data=02%7C01%7CKevin1.Wang%40amd.com%7C4895e14d1c14407add8208d794a6ccdc%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C637141316451781456&amp;sdata=LJLHaR5O38HuI%2Bu0KZEkoCJcejrqNcZcUDV6w09pVyk%3D&amp;reserved=0">https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.freedesktop.org%2Fmailman%2Flistinfo%2Famd-gfx&amp;data=02%7C01%7CKevin1.Wang%40amd.com%7C4895e14d1c14407add8208d794a6ccdc%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C637141316451781456&amp;sdata=LJLHaR5O38HuI%2Bu0KZEkoCJcejrqNcZcUDV6w09pVyk%3D&amp;reserved=0</a><br>
</div>
</span></font></div>
</div>
</body>
</html>