<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);">
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 Huang Rui <ray.huang@amd.com><br>
<b>Sent:</b> Monday, July 27, 2020 4:23 PM<br>
<b>To:</b> amd-gfx@lists.freedesktop.org <amd-gfx@lists.freedesktop.org><br>
<b>Cc:</b> Huang, Ray <Ray.Huang@amd.com><br>
<b>Subject:</b> [PATCH] drm/amdgpu: skip crit temperature values on APU</font>
<div> </div>
</div>
<div class="BodyFragment"><font size="2"><span style="font-size:11pt">
<div class="PlainText">It doesn't expose PPTable descriptor on APU platform. So max/min<br>
temperature values cannot be got from APU platform.<br>
<br>
Signed-off-by: Huang Rui <ray.huang@amd.com><br>
---<br>
<br>
This patch needs to backport to stable tree.<br>
<br>
Thanks,<br>
Ray<br>
<br>
---<br>
drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c | 6 ++++++<br>
1 file changed, 6 insertions(+)<br>
<br>
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c<br>
index 5f20cadee343..65ddf575ccbc 100644<br>
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c<br>
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c<br>
@@ -3212,6 +3212,12 @@ static umode_t hwmon_attributes_visible(struct kobject *kobj,<br>
attr == &sensor_dev_attr_fan1_enable.dev_attr.attr))<br>
return 0;<br>
<br>
+ /* Skip crit temp on APU */<br>
+ if ((adev->flags & AMD_IS_APU) && (adev->family >= AMDGPU_FAMILY_RV) &&<br>
+ (attr == &sensor_dev_attr_temp1_crit.dev_attr.attr ||<br>
+ attr == &sensor_dev_attr_temp1_crit_hyst.dev_attr.attr))<br>
+ return 0;<br>
+<br>
/* Skip limit attributes if DPM is not enabled */<br>
if (!adev->pm.dpm_enabled &&<br>
(attr == &sensor_dev_attr_temp1_crit.dev_attr.attr ||<br>
-- <br>
2.25.1<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&data=02%7C01%7CKevin1.Wang%40amd.com%7C73c50b729f024e67b23c08d832067d7c%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C637314350778753140&sdata=D3wb3uQxXJJkj%2Bb4XuBxrb2oYnTUq9jHQNiAe4ctSlU%3D&reserved=0">https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.freedesktop.org%2Fmailman%2Flistinfo%2Famd-gfx&data=02%7C01%7CKevin1.Wang%40amd.com%7C73c50b729f024e67b23c08d832067d7c%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C637314350778753140&sdata=D3wb3uQxXJJkj%2Bb4XuBxrb2oYnTUq9jHQNiAe4ctSlU%3D&reserved=0</a><br>
</div>
</span></font></div>
</div>
</body>
</html>