<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<style type="text/css" style="display:none;"><!-- P {margin-top:0;margin-bottom:0;} --></style>
</head>
<body dir="ltr">
<div id="divtagdefaultwrapper" style="font-size:12pt;color:#000000;font-family:Calibri,Helvetica,sans-serif;" dir="ltr">
<p style="margin-top:0;margin-bottom:0">Acked-by: Alex Deucher <alexander.deucher@amd.com><br>
</p>
</div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>From:</b> amd-gfx <amd-gfx-bounces@lists.freedesktop.org> on behalf of Rex Zhu <Rex.Zhu@amd.com><br>
<b>Sent:</b> Wednesday, August 15, 2018 11:42:39 PM<br>
<b>To:</b> amd-gfx@lists.freedesktop.org; Francis, David<br>
<b>Cc:</b> Zhu, Rex<br>
<b>Subject:</b> [PATCH] drm/amd/display: Fix bug use wrong pp interface</font>
<div> </div>
</div>
<div class="BodyFragment"><font size="2"><span style="font-size:11pt;">
<div class="PlainText">Used wrong pp interface, the original interface is<br>
exposed by dpm on SI and paritial CI.<br>
<br>
Pointed out by Francis David <david.francis@amd.com><br>
<br>
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com><br>
---<br>
 drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_pp_smu.c | 9 +++++++--<br>
 1 file changed, 7 insertions(+), 2 deletions(-)<br>
<br>
diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_pp_smu.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_pp_smu.c<br>
index e5c5b0a..85b72d459 100644<br>
--- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_pp_smu.c<br>
+++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_pp_smu.c<br>
@@ -480,12 +480,17 @@ void pp_rv_set_display_requirement(struct pp_smu *pp,<br>
 {<br>
         const struct dc_context *ctx = pp->dm;<br>
         struct amdgpu_device *adev = ctx->driver_context;<br>
+       void *pp_handle = adev->powerplay.pp_handle;<br>
         const struct amd_pm_funcs *pp_funcs = adev->powerplay.pp_funcs;<br>
 <br>
-       if (!pp_funcs || !pp_funcs->display_configuration_changed)<br>
+       if (!req || !pp_funcs || !pp_funcs->display_configuration_changed)<br>
                 return;<br>
 <br>
-       amdgpu_dpm_display_configuration_changed(adev);<br>
+       adev->pm.pm_display_cfg.min_dcef_deep_sleep_set_clk = req->min_deep_sleep_dcefclk_mhz/10;<br>
+       adev->pm.pm_display_cfg.min_dcef_set_clk = req->hard_min_dcefclk_khz/10;<br>
+       adev->pm.pm_display_cfg.num_display = req->display_count;<br>
+       adev->pm.pm_display_cfg.min_core_set_clock = req->hard_min_fclk_khz/10;<br>
+       pp_funcs->display_configuration_change(pp_handle, &adev->pm.pm_display_cfg);<br>
 }<br>
 <br>
 void pp_rv_set_wm_ranges(struct pp_smu *pp,<br>
-- <br>
1.9.1<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><br>
</div>
</span></font></div>
</body>
</html>