<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">
<p style="font-family:Arial;font-size:10pt;color:#0000FF;margin:5pt;" align="Left">
[AMD Official Use Only]<br>
</p>
<br>
<div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Thank you very much Harry!</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);">
Regards,</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Rico<br>
</div>
<div id="appendonsend"></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> Wentland, Harry <Harry.Wentland@amd.com><br>
<b>Sent:</b> Tuesday, March 8, 2022 21:55<br>
<b>To:</b> Yin, Tianci (Rico) <Tianci.Yin@amd.com>; amd-gfx@lists.freedesktop.org <amd-gfx@lists.freedesktop.org><br>
<b>Cc:</b> Wang, Yu (Charlie) <Yu.Wang4@amd.com>; Zhuo, Qingqing (Lillian) <Qingqing.Zhuo@amd.com>; Liu, Wenjing <Wenjing.Liu@amd.com>; Chen, Guchun <Guchun.Chen@amd.com><br>
<b>Subject:</b> Re: [PATCH] drm/amd/display: fix dp kvm can't light up</font>
<div> </div>
</div>
<div class="BodyFragment"><font size="2"><span style="font-size:11pt;">
<div class="PlainText">On 2022-03-08 01:50, Tianci Yin wrote:<br>
> From: "Tianci.Yin" <tianci.yin@amd.com><br>
> <br>
> [why]<br>
> The DP KVM failed to light up, since the lttpr_mode is not reset to<br>
> default value when failed to read LTTPR capabilities, and the<br>
> variable max_link_rate retains a initial value zero, this cause variable<br>
> link_rate be assigned to an error value zero, consquently pixel_clock<br>
> get wrong value zero, and kvm can't light up.<br>
> <br>
> [how]<br>
> Reset lttpr_mode to default value when failed to read LTTPR<br>
> capabilities, so that the link_rate fallbacks to the minimum rate that<br>
> supported by link encoder and sink.<br>
> <br>
> Signed-off-by: Tianci.Yin <tianci.yin@amd.com><br>
<br>
Reviewed-by: Harry Wentland <harry.wentland@amd.com><br>
<br>
Harry<br>
<br>
> ---<br>
> drivers/gpu/drm/amd/display/dc/core/dc_link_dp.c | 1 +<br>
> 1 file changed, 1 insertion(+)<br>
> <br>
> diff --git a/drivers/gpu/drm/amd/display/dc/core/dc_link_dp.c b/drivers/gpu/drm/amd/display/dc/core/dc_link_dp.c<br>
> index 5688b15ca9e6..f9ae06103241 100644<br>
> --- a/drivers/gpu/drm/amd/display/dc/core/dc_link_dp.c<br>
> +++ b/drivers/gpu/drm/amd/display/dc/core/dc_link_dp.c<br>
> @@ -5101,6 +5101,7 @@ bool dp_retrieve_lttpr_cap(struct dc_link *link)<br>
> sizeof(lttpr_dpcd_data));<br>
> if (status != DC_OK) {<br>
> DC_LOG_DP2("%s: Read LTTPR caps data failed.\n", __func__);<br>
> + link->lttpr_mode = LTTPR_MODE_NON_LTTPR;<br>
> return false;<br>
> }<br>
> <br>
<br>
</div>
</span></font></div>
</div>
</body>
</html>